1#if 0  // disabled
2// Copyright 2019 Google LLC.
3// Use of this source code is governed by a BSD-style license that can be found in the LICENSE file.
4#include "tools/fiddle/examples.h"
5// HASH=6a63dfdd62ab77ff57783af8c33d7b78
6REG_FIDDLE(ImageInfo_ByteSizeOverflowed, 256, 256, true, 0) {
7void draw(SkCanvas* canvas) {
8    if (sizeof(size_t) == 8) {
9        SkImageInfo info = SkImageInfo::MakeN32Premul(2, 1000000000);
10        for (size_t rowBytes = 100000000; rowBytes < 10000000000000LL; rowBytes *= 10) {
11            const size_t size = info.computeByteSize(rowBytes);
12            SkDebugf("rowBytes:%llu size:%llu overflowed:%s\n", rowBytes, size,
13                     SkImageInfo::ByteSizeOverflowed(size) ? "true" : "false");
14        }
15    }
16}
17}  // END FIDDLE
18#endif  // disabled
19