#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */

/* Type definitions */

/* Variables and functions */
int /*<<< orphan*/ print_copyright();
int /*<<< orphan*/ print_version(char *);
int /*<<< orphan*/ printf(char *, char *);
scalar_t__ strlen(char *);
int /*<<< orphan*/ usage();
void print_help() {
  printf("\nTool name:\n   %s\n", "resample");
  usage();
  printf("Description:\n%s\n\n",
         "   The resample tool resamples the input file to produce a new\n"
         "   file with the given pixel size, or scaled by the given scale\n"
         "   factor(s).\n\n"
         "   If the input file is multi-banded, resample will apply the\n"
         "   resampling to each band separately.\n");
  if (strlen(
          "   <infile>  The basename of the input data file.\n\n"
          "   You have several different ways of specifying the size of the\n"
          "   output image:\n\n"
          "     X and Y Pixel Sizes:\n"
          "       resample <x pixel size> <y pixel size> infile outfile\n"
          "     Square Pixels (Equal X and Y Pixel Sizes):\n"
          "       resample -square <pixel size> infile outfile\n"
          "     X and Y Scale Factors:\n"
          "       resample -scalex <x scale factor> -scaley <y scale factor>\n"
          "                infile outfile\n"
          "     Output has a specified maximum size:\n"
          "       resample -size <size>\n"
          "     Uniform Scaling (Equal X and Y Scale Factors):\n"
          "       resample -scale <scale factor> infile outfile\n\n"))
    printf("Input:\n%s\n\n",
           "   <infile>  The basename of the input data file.\n\n"
           "   You have several different ways of specifying the size of the\n"
           "   output image:\n\n"
           "     X and Y Pixel Sizes:\n"
           "       resample <x pixel size> <y pixel size> infile outfile\n"
           "     Square Pixels (Equal X and Y Pixel Sizes):\n"
           "       resample -square <pixel size> infile outfile\n"
           "     X and Y Scale Factors:\n"
           "       resample -scalex <x scale factor> -scaley <y scale factor>\n"
           "                infile outfile\n"
           "     Output has a specified maximum size:\n"
           "       resample -size <size>\n"
           "     Uniform Scaling (Equal X and Y Scale Factors):\n"
           "       resample -scale <scale factor> infile outfile\n\n");
  if (strlen("   <outfile>  The basename of the output file.\n"))
    printf("Output:\n%s\n\n",
           "   <outfile>  The basename of the output file.\n");
  if (strlen(
          "   -square <pixel size, in meters>\n"
          "        Creates an output image with square pixels of the given "
          "size.\n"
          "        May not be used with -scale,-scalex, or -scaley.\n"
          "   -scale <scale factor>\n"
          "        Creates an ouput image that is larger by the given factor, "
          "in\n"
          "        each direction.  For example, using a scale factor of 1/2 "
          "will\n"
          "        result in an image with half as many lines, and half as "
          "many\n"
          "        samples.  May not be used with -square,-scalex, or "
          "-scaley.\n"
          "   -scalex <x scale factor>\n"
          "        Creates an ouput image that is larger by the given factor, "
          "in\n"
          "        the x direction.  You must also specify a y scale factor "
          "when\n"
          "        using this option.  (-scaley)\n"
          "   -scaley <y scale factor>\n"
          "        Creates an ouput image that is larger by the given factor, "
          "in\n"
          "        the y direction.  You must also specify a x scale factor "
          "when\n"
          "        using this option.  (-scalex)\n"
          "   -nearest_neighbor ( -nn )\n"
          "        Don't average pixels when interpolating, use the nearest.\n"
          "   -logical_or (-lo)\n"
          "        Don't average pixels when interpolation, use a logical or "
          "operation.\n"
          "   -license\n"
          "        Print copyright and license for this software then exit.\n"
          "   -version\n"
          "        Print version and copyright then exit.\n"
          "   -help\n"
          "        Print this help information and then exit."))
    printf(
        "Options:\n%s\n\n",
        "   -square <pixel size, in meters>\n"
        "        Creates an output image with square pixels of the given "
        "size.\n"
        "        May not be used with -scale,-scalex, or -scaley.\n"
        "   -scale <scale factor>\n"
        "        Creates an ouput image that is larger by the given factor, "
        "in\n"
        "        each direction.  For example, using a scale factor of 1/2 "
        "will\n"
        "        result in an image with half as many lines, and half as many\n"
        "        samples.  May not be used with -square,-scalex, or -scaley.\n"
        "   -scalex <x scale factor>\n"
        "        Creates an ouput image that is larger by the given factor, "
        "in\n"
        "        the x direction.  You must also specify a y scale factor "
        "when\n"
        "        using this option.  (-scaley)\n"
        "   -scaley <y scale factor>\n"
        "        Creates an ouput image that is larger by the given factor, "
        "in\n"
        "        the y direction.  You must also specify a x scale factor "
        "when\n"
        "        using this option.  (-scalex)\n"
        "   -nearest_neighbor ( -nn )\n"
        "        Don't average pixels when interpolating, use the nearest.\n"
        "   -logical_or (-lo)\n"
        "        Don't average pixels when interpolation, use a logical or "
        "operation.\n"
        "   -license\n"
        "        Print copyright and license for this software then exit.\n"
        "   -version\n"
        "        Print version and copyright then exit.\n"
        "   -help\n"
        "        Print this help information and then exit.");
  if (strlen("   Produce an output image (b) with 100x100 meter pixels:\n"
             "   > resample -square 100 a b\n\n"
             "   Produce an output image with 100x200 meter pixels:\n"
             "   > resample 100 200 a b\n\n"
             "   Create an image 1/8 as large in each direction (1/64):\n"
             "   > resample -scale 8 a b\n"))
    printf("Examples:\n%s\n\n",
           "   Produce an output image (b) with 100x100 meter pixels:\n"
           "   > resample -square 100 a b\n\n"
           "   Produce an output image with 100x200 meter pixels:\n"
           "   > resample 100 200 a b\n\n"
           "   Create an image 1/8 as large in each direction (1/64):\n"
           "   > resample -scale 8 a b\n");
  if (strlen("   resample only works on ASF Internal format files (.img)"))
    printf("Limitations:\n%s\n\n",
           "   resample only works on ASF Internal format files (.img)");
  if (strlen(""))
    printf("See Also:\n%s\n\n", "");
  printf("Contact:\n%s\n", "   "
                           "Alaska Satellite Facility"
                           "\n"
                           "   "
                           "Geophysical Institute"
                           "\n"
                           "   "
                           "University of Alaska Fairbanks"
                           "\n"
                           "   "
                           "P.O. Box 757320"
                           "\n"
                           "   "
                           "Fairbanks, AK 99775-7320"
                           "\n"
                           "   "
                           "http://www.asf.alaska.edu"
                           "\n"
                           "   "
                           "uso@asf.alaska.edu"
                           "\n");
  print_version("resample");
  print_copyright();
}


x86 assembly (clang, -O0):
<print_help>:
push   %rbp
mov    %rsp,%rbp
lea    0xea5(%rip),%rdi
lea    0xeb1(%rip),%rsi
call   1050 <printf@plt>
mov    $0x0,%al
call   1070 <usage@plt>
lea    0xea7(%rip),%rdi
lea    0xeb2(%rip),%rsi
call   1050 <printf@plt>
lea    0xf9a(%rip),%rdi
call   1040 <strlen@plt>
cmp    $0x0,%rax
je     11aa <print_help+0x5a>
lea    0x11f4(%rip),%rdi
lea    0xf7d(%rip),%rsi
call   1050 <printf@plt>
lea    0x11ed(%rip),%rdi
call   1040 <strlen@plt>
cmp    $0x0,%rax
je     11d3 <print_help+0x83>
lea    0x1207(%rip),%rdi
lea    0x11d0(%rip),%rsi
call   1050 <printf@plt>
lea    0x1201(%rip),%rdi
call   1040 <strlen@plt>
cmp    $0x0,%rax
je     11fc <print_help+0xac>
lea    0x16dd(%rip),%rdi
lea    0x11e4(%rip),%rsi
call   1050 <printf@plt>
lea    0x16d8(%rip),%rdi
call   1040 <strlen@plt>
cmp    $0x0,%rax
je     1225 <print_help+0xd5>
lea    0x17c2(%rip),%rdi
lea    0x16bb(%rip),%rsi
call   1050 <printf@plt>
lea    0x17be(%rip),%rdi
call   1040 <strlen@plt>
cmp    $0x0,%rax
je     124e <print_help+0xfe>
lea    0x17e3(%rip),%rdi
lea    0x17a1(%rip),%rsi
call   1050 <printf@plt>
lea    0x113c(%rip),%rdi
call   1040 <strlen@plt>
cmp    $0x0,%rax
je     1277 <print_help+0x127>
lea    0x17cc(%rip),%rdi
lea    0x111f(%rip),%rsi
call   1050 <printf@plt>
lea    0x17c8(%rip),%rdi
lea    0x17ce(%rip),%rsi
call   1050 <printf@plt>
lea    0xd82(%rip),%rdi
call   1030 <print_version@plt>
mov    $0x0,%al
call   1060 <print_copyright@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<print_help>:
push   %rbx
lea    0xeb8(%rip),%rdi
lea    0xec4(%rip),%rbx
mov    %rbx,%rsi
call   1040 <printf@plt>
xor    %eax,%eax
call   1060 <usage@plt>
lea    0xeb7(%rip),%rdi
lea    0xec2(%rip),%rsi
call   1040 <printf@plt>
lea    0x121a(%rip),%rdi
lea    0xfa3(%rip),%rsi
call   1040 <printf@plt>
lea    0x1243(%rip),%rdi
lea    0x120c(%rip),%rsi
call   1040 <printf@plt>
lea    0x172f(%rip),%rdi
lea    0x1236(%rip),%rsi
call   1040 <printf@plt>
lea    0x182a(%rip),%rdi
lea    0x1723(%rip),%rsi
call   1040 <printf@plt>
lea    0x1861(%rip),%rdi
lea    0x181f(%rip),%rsi
call   1040 <printf@plt>
lea    0x1860(%rip),%rdi
lea    0x1866(%rip),%rsi
call   1040 <printf@plt>
mov    %rbx,%rdi
call   1030 <print_version@plt>
xor    %eax,%eax
pop    %rbx
jmp    1050 <print_copyright@plt>

LLVM IR (-O0):
@.str = [19 x i8] c"\0ATool name:\0A %s\0A\00"
@.str.1 = [9 x i8] c"resample\00"
@.str.2 = [18 x i8] c"Description:\0A%s\0A\0A\00"
@.str.3 = [244 x i8] c" The resample tool resamples the input file to produce a new\0A file with the given pixel size, or scaled by the given scale\0A factor(s).\0A\0A If the input file is multi-banded, resample will apply the\0A resampling to each band separately.\0A\00"
@.str.4 = [624 x i8] c" <infile> The basename of the input data file.\0A\0A You have several different ways of specifying the size of the\0A output image:\0A\0A X and Y Pixel Sizes:\0A resample <x pixel size> <y pixel size> infile outfile\0A Square Pixels (Equal X and Y Pixel Sizes):\0A resample -square <pixel size> infile outfile\0A X and Y Scale Factors:\0A resample -scalex <x scale factor> -scaley <y scale factor>\0A infile outfile\0A Output has a specified maximum size:\0A resample -size <size>\0A Uniform Scaling (Equal X and Y Scale Factors):\0A resample -scale <scale factor> infile outfile\0A\0A\00"
@.str.5 = [12 x i8] c"Input:\0A%s\0A\0A\00"
@.str.6 = [48 x i8] c" <outfile> The basename of the output file.\0A\00"
@.str.7 = [13 x i8] c"Output:\0A%s\0A\0A\00"
@.str.8 = [1266 x i8] c" -square <pixel size, in meters>\0A Creates an output image with square pixels of the given size.\0A May not be used with -scale,-scalex, or -scaley.\0A -scale <scale factor>\0A Creates an ouput image that is larger by the given factor, in\0A each direction. For example, using a scale factor of 1/2 will\0A result in an image with half as many lines, and half as many\0A samples. May not be used with -square,-scalex, or -scaley.\0A -scalex <x scale factor>\0A Creates an ouput image that is larger by the given factor, in\0A the x direction. You must also specify a y scale factor when\0A using this option. (-scaley)\0A -scaley <y scale factor>\0A Creates an ouput image that is larger by the given factor, in\0A the y direction. You must also specify a x scale factor when\0A using this option. (-scalex)\0A -nearest_neighbor ( -nn )\0A Don't average pixels when interpolating, use the nearest.\0A -logical_or (-lo)\0A Don't average pixels when interpolation, use a logical or operation.\0A -license\0A Print copyright and license for this software then exit.\0A -version\0A Print version and copyright then exit.\0A -help\0A Print this help information and then exit.\00"
@.str.9 = [14 x i8] c"Options:\0A%s\0A\0A\00"
@.str.10 = [256 x i8] c" Produce an output image (b) with 100x100 meter pixels:\0A > resample -square 100 a b\0A\0A Produce an output image with 100x200 meter pixels:\0A > resample 100 200 a b\0A\0A Create an image 1/8 as large in each direction (1/64):\0A > resample -scale 8 a b\0A\00"
@.str.11 = [15 x i8] c"Examples:\0A%s\0A\0A\00"
@.str.12 = [59 x i8] c" resample only works on ASF Internal format files (.img)\00"
@.str.13 = [18 x i8] c"Limitations:\0A%s\0A\0A\00"
@.str.14 = [1 x i8] zeroinitializer
@.str.15 = [15 x i8] c"See Also:\0A%s\0A\0A\00"
@.str.16 = [13 x i8] c"Contact:\0A%s\0A\00"
@.str.17 = [187 x i8] c" Alaska Satellite Facility\0A Geophysical Institute\0A University of Alaska Fairbanks\0A P.O. Box 757320\0A Fairbanks, AK 99775-7320\0A http://www.asf.alaska.edu\0A uso@asf.alaska.edu\0A\00"
define void @print_help() {
%1 = call i32 @printf(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0))
%2 = call i32 (...) @usage()
%3 = call i32 @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([244 x i8], [244 x i8]* @.str.3, i64 0, i64 0))
%4 = call i64 @strlen(i8* getelementptr inbounds ([624 x i8], [624 x i8]* @.str.4, i64 0, i64 0))
%5 = icmp ne i64 %4, 0
br i1 %5, label %6, label %8
6: ; preds = %0
%7 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.5, i64 0, i64 0), i8* getelementptr inbounds ([624 x i8], [624 x i8]* @.str.4, i64 0, i64 0))
br label %8
8: ; preds = %6, %0
%9 = call i64 @strlen(i8* getelementptr inbounds ([48 x i8], [48 x i8]* @.str.6, i64 0, i64 0))
%10 = icmp ne i64 %9, 0
br i1 %10, label %11, label %13
11: ; preds = %8
%12 = call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.7, i64 0, i64 0), i8* getelementptr inbounds ([48 x i8], [48 x i8]* @.str.6, i64 0, i64 0))
br label %13
13: ; preds = %11, %8
%14 = call i64 @strlen(i8* getelementptr inbounds ([1266 x i8], [1266 x i8]* @.str.8, i64 0, i64 0))
%15 = icmp ne i64 %14, 0
br i1 %15, label %16, label %18
16: ; preds = %13
%17 = call i32 @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.9, i64 0, i64 0), i8* getelementptr inbounds ([1266 x i8], [1266 x i8]* @.str.8, i64 0, i64 0))
br label %18
18: ; preds = %16, %13
%19 = call i64 @strlen(i8* getelementptr inbounds ([256 x i8], [256 x i8]* @.str.10, i64 0, i64 0))
%20 = icmp ne i64 %19, 0
br i1 %20, label %21, label %23
21: ; preds = %18
%22 = call i32 @printf(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.11, i64 0, i64 0), i8* getelementptr inbounds ([256 x i8], [256 x i8]* @.str.10, i64 0, i64 0))
br label %23
23: ; preds = %21, %18
%24 = call i64 @strlen(i8* getelementptr inbounds ([59 x i8], [59 x i8]* @.str.12, i64 0, i64 0))
%25 = icmp ne i64 %24, 0
br i1 %25, label %26, label %28
26: ; preds = %23
%27 = call i32 @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.13, i64 0, i64 0), i8* getelementptr inbounds ([59 x i8], [59 x i8]* @.str.12, i64 0, i64 0))
br label %28
28: ; preds = %26, %23
%29 = call i64 @strlen(i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.14, i64 0, i64 0))
%30 = icmp ne i64 %29, 0
br i1 %30, label %31, label %33
31: ; preds = %28
%32 = call i32 @printf(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.15, i64 0, i64 0), i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.14, i64 0, i64 0))
br label %33
33: ; preds = %31, %28
%34 = call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.16, i64 0, i64 0), i8* getelementptr inbounds ([187 x i8], [187 x i8]* @.str.17, i64 0, i64 0))
%35 = call i32 @print_version(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0))
%36 = call i32 (...) @print_copyright()
ret void
}

LLVM IR (-O2):
@.str = [19 x i8] c"\0ATool name:\0A %s\0A\00"
@.str.1 = [9 x i8] c"resample\00"
@.str.2 = [18 x i8] c"Description:\0A%s\0A\0A\00"
@.str.3 = [244 x i8] c" The resample tool resamples the input file to produce a new\0A file with the given pixel size, or scaled by the given scale\0A factor(s).\0A\0A If the input file is multi-banded, resample will apply the\0A resampling to each band separately.\0A\00"
@.str.4 = [624 x i8] c" <infile> The basename of the input data file.\0A\0A You have several different ways of specifying the size of the\0A output image:\0A\0A X and Y Pixel Sizes:\0A resample <x pixel size> <y pixel size> infile outfile\0A Square Pixels (Equal X and Y Pixel Sizes):\0A resample -square <pixel size> infile outfile\0A X and Y Scale Factors:\0A resample -scalex <x scale factor> -scaley <y scale factor>\0A infile outfile\0A Output has a specified maximum size:\0A resample -size <size>\0A Uniform Scaling (Equal X and Y Scale Factors):\0A resample -scale <scale factor> infile outfile\0A\0A\00"
@.str.5 = [12 x i8] c"Input:\0A%s\0A\0A\00"
@.str.6 = [48 x i8] c" <outfile> The basename of the output file.\0A\00"
@.str.7 = [13 x i8] c"Output:\0A%s\0A\0A\00"
@.str.8 = [1266 x i8] c" -square <pixel size, in meters>\0A Creates an output image with square pixels of the given size.\0A May not be used with -scale,-scalex, or -scaley.\0A -scale <scale factor>\0A Creates an ouput image that is larger by the given factor, in\0A each direction. For example, using a scale factor of 1/2 will\0A result in an image with half as many lines, and half as many\0A samples. May not be used with -square,-scalex, or -scaley.\0A -scalex <x scale factor>\0A Creates an ouput image that is larger by the given factor, in\0A the x direction. You must also specify a y scale factor when\0A using this option. (-scaley)\0A -scaley <y scale factor>\0A Creates an ouput image that is larger by the given factor, in\0A the y direction. You must also specify a x scale factor when\0A using this option. (-scalex)\0A -nearest_neighbor ( -nn )\0A Don't average pixels when interpolating, use the nearest.\0A -logical_or (-lo)\0A Don't average pixels when interpolation, use a logical or operation.\0A -license\0A Print copyright and license for this software then exit.\0A -version\0A Print version and copyright then exit.\0A -help\0A Print this help information and then exit.\00"
@.str.9 = [14 x i8] c"Options:\0A%s\0A\0A\00"
@.str.10 = [256 x i8] c" Produce an output image (b) with 100x100 meter pixels:\0A > resample -square 100 a b\0A\0A Produce an output image with 100x200 meter pixels:\0A > resample 100 200 a b\0A\0A Create an image 1/8 as large in each direction (1/64):\0A > resample -scale 8 a b\0A\00"
@.str.11 = [15 x i8] c"Examples:\0A%s\0A\0A\00"
@.str.12 = [59 x i8] c" resample only works on ASF Internal format files (.img)\00"
@.str.13 = [18 x i8] c"Limitations:\0A%s\0A\0A\00"
@.str.16 = [13 x i8] c"Contact:\0A%s\0A\00"
@.str.17 = [187 x i8] c" Alaska Satellite Facility\0A Geophysical Institute\0A University of Alaska Fairbanks\0A P.O. Box 757320\0A Fairbanks, AK 99775-7320\0A http://www.asf.alaska.edu\0A uso@asf.alaska.edu\0A\00"
define void @print_help() {
%1 = tail call i32 @printf(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0))
%2 = tail call i32 (...) @usage()
%3 = tail call i32 @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([244 x i8], [244 x i8]* @.str.3, i64 0, i64 0))
%4 = tail call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.5, i64 0, i64 0), i8* getelementptr inbounds ([624 x i8], [624 x i8]* @.str.4, i64 0, i64 0))
%5 = tail call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.7, i64 0, i64 0), i8* getelementptr inbounds ([48 x i8], [48 x i8]* @.str.6, i64 0, i64 0))
%6 = tail call i32 @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.9, i64 0, i64 0), i8* getelementptr inbounds ([1266 x i8], [1266 x i8]* @.str.8, i64 0, i64 0))
%7 = tail call i32 @printf(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.11, i64 0, i64 0), i8* getelementptr inbounds ([256 x i8], [256 x i8]* @.str.10, i64 0, i64 0))
%8 = tail call i32 @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.13, i64 0, i64 0), i8* getelementptr inbounds ([59 x i8], [59 x i8]* @.str.12, i64 0, i64 0))
%9 = tail call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.16, i64 0, i64 0), i8* getelementptr inbounds ([187 x i8], [187 x i8]* @.str.17, i64 0, i64 0))
%10 = tail call i32 @print_version(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0))
%11 = tail call i32 (...) @print_copyright()
ret void
}