#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*/ fprintf(int /*<<< orphan*/, char *, char *);
int /*<<< orphan*/ stderr;
void usage(char *progname) {
  fprintf(
      stderr,
      "usage: %s -{flags}  where:\n"
      "   -h gives usage message\n"
      "   -f FILE sets filename into which to store image [wincd.pnm]\n"
      "   -s SCRIPT - runs when file saved, FILE is only arg. [no default]\n"
      "   -p SECS - sleep interval when polling to see if image changed [10]\n"
      "   -w SECS - sleep interval to wait after image has been snapped [60]\n"
      "   -n N - how many images for which to track history [6]\n"
      "	(use \"-n 0\" for simple save-every-time operation)\n"
      "    -r N - change in pixel (as %% of max) to be called changed [25]\n"
      "    -m N - percent of pixels changed for image to be different [4]\n"
      "   -z N - image reduction factor (one of 1, 2, 4, or 8) [1]\n"
      "   -2 to double-scan an image\n"
      "   -g grabs a greyscale image\n"
      "   -c grabs a color image (default)\n"
      "   -l color-adjustment\n"
      "   -a causes an audible alert (beep) when image is exposed\n"
      "   -i IDSTRING assigns a prefix for all config info looked up\n"
      "   -t STR sets tracing: see winc usage message\n"
      "",
      progname);
}


x86 assembly (clang, -O0):
<usage>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    0x2ebd(%rip),%rax
mov    (%rax),%edi
mov    -0x8(%rbp),%rdx
lea    0xed0(%rip),%rsi
call   1030 <fprintf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<usage>:
mov    %rdi,%rdx
mov    0x2ec6(%rip),%rax
mov    (%rax),%edi
lea    0xedd(%rip),%rsi
jmp    1030 <fprintf@plt>

LLVM IR (-O0):
@stderr = global i32 0
@.str = [915 x i8] c"usage: %s -{flags} where:\0A -h gives usage message\0A -f FILE sets filename into which to store image [wincd.pnm]\0A -s SCRIPT - runs when file saved, FILE is only arg. [no default]\0A -p SECS - sleep interval when polling to see if image changed [10]\0A -w SECS - sleep interval to wait after image has been snapped [60]\0A -n N - how many images for which to track history [6]\0A\09(use \22-n 0\22 for simple save-every-time operation)\0A -r N - change in pixel (as %% of max) to be called changed [25]\0A -m N - percent of pixels changed for image to be different [4]\0A -z N - image reduction factor (one of 1, 2, 4, or 8) [1]\0A -2 to double-scan an image\0A -g grabs a greyscale image\0A -c grabs a color image (default)\0A -l color-adjustment\0A -a causes an audible alert (beep) when image is exposed\0A -i IDSTRING assigns a prefix for all config info looked up\0A -t STR sets tracing: see winc usage message\0A\00"
define void @usage(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i32, i32* @stderr
%4 = load i8*, i8** %2
%5 = call i32 @fprintf(i32 %3, i8* getelementptr inbounds ([915 x i8], [915 x i8]* @.str, i64 0, i64 0), i8* %4)
ret void
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [915 x i8] c"usage: %s -{flags} where:\0A -h gives usage message\0A -f FILE sets filename into which to store image [wincd.pnm]\0A -s SCRIPT - runs when file saved, FILE is only arg. [no default]\0A -p SECS - sleep interval when polling to see if image changed [10]\0A -w SECS - sleep interval to wait after image has been snapped [60]\0A -n N - how many images for which to track history [6]\0A\09(use \22-n 0\22 for simple save-every-time operation)\0A -r N - change in pixel (as %% of max) to be called changed [25]\0A -m N - percent of pixels changed for image to be different [4]\0A -z N - image reduction factor (one of 1, 2, 4, or 8) [1]\0A -2 to double-scan an image\0A -g grabs a greyscale image\0A -c grabs a color image (default)\0A -l color-adjustment\0A -a causes an audible alert (beep) when image is exposed\0A -i IDSTRING assigns a prefix for all config info looked up\0A -t STR sets tracing: see winc usage message\0A\00"
define void @usage(i8* %0) {
%2 = load i32, i32* @stderr
%3 = tail call i32 @fprintf(i32 %2, i8* getelementptr inbounds ([915 x i8], [915 x i8]* @.str, i64 0, i64 0), i8* %0)
ret void
}