#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*/ exit(int);
int /*<<< orphan*/ printf(char *);
void usage(void) {
  printf("usage: scramble [options] <input file> <output file> [xor string]\n");
  printf("options:\n"
         "\t-fm     Archos FM recorder format\n"
         "\t-v2     Archos V2 recorder format\n"
         "\t-ofm    Archos Ondio FM recorder format\n"
         "\t-osp    Archos Ondio SP format\n"
         "\t-neo    SSI Neo format\n"
         "\t-mm=X   Archos Multimedia format (X values: A=JBMM, B=AV1xx, "
         "C=AV3xx)\n"
         "\t-iriver iRiver format\n"
         "\t-iaudiox5 iAudio X5 format\n"
         "\t-iaudiox5v iAudio X5V format\n"
         "\t-iaudiom5 iAudio M5 format\n"
         "\t-iaudiom3 iAudio M3 format\n");
  printf("\t-ipod3g ipod firmware partition format (3rd Gen)\n"
         "\t-ipod4g ipod firmware partition format (4th Gen, Mini, Nano, "
         "Photo/Color)\n"
         "\t-ipod5g ipod firmware partition format (5th Gen - aka Video)\n"
         "\t-creative=X Creative firmware structure format\n"
         "\t            (X values: zvm, zvm60, zenvision\n"
         "\t                       zenv, zen\n");
  printf("\t-gigabeat Toshiba Gigabeat F/X format\n"
         "\t-gigabeats Toshiba Gigabeat S format\n"
         "\t-mi4v2  PortalPlayer .mi4 format (revision 010201)\n"
         "\t-mi4v3  PortalPlayer .mi4 format (revision 010301)\n"
         "\t-mi4r   Sandisk Rhapsody .mi4 format\n"
         "\t        All mi4 options take two optional arguments:\n");
  printf(
      "\t        -model=XXXX   where XXXX is the model id string\n"
      "\t        -type=XXXX    where XXXX is a string indicating the \n"
      "\t                      type of binary, eg. RBOS, RBBL\n"
      "\t-tcc=X  Telechips generic firmware format (X values: sum, crc)\n"
      "\t-add=X  Rockbox generic \"add-up\" checksum format\n"
      "\t        (X values: h100, h120, h140, h300, ipco, nano, ipvd, mn2g\n"
      "\t                   ip3g, ip4g, mini, iax5, iam5, iam3, h10, h10_5gb,\n"
      "\t                   tpj2, c200, e200, giga, gigs, m100, m500, d2,\n");
  printf(
      "\t                   9200, 1630, 6330, ldax, m200, c100, clip, e2v2,\n"
      "\t                   m2v4, fuze, c2v2, clv2, y820, y920, y925, x747,\n"
      "\t                   747p, x777, nn2g, m244, cli+, fuz2, hd20, hd30,\n"
      "\t                   ip6g)\n");
  printf("\nNo option results in Archos standard player/recorder format.\n");
  exit(1);
}


x86 assembly (clang, -O0):
<usage>:
push   %rbp
mov    %rsp,%rbp
lea    0xed5(%rip),%rdi
call   1030 <printf@plt>
lea    0xf0c(%rip),%rdi
call   1030 <printf@plt>
lea    0x1081(%rip),%rdi
call   1030 <printf@plt>
lea    0x11b1(%rip),%rdi
call   1030 <printf@plt>
lea    0x12b7(%rip),%rdi
call   1030 <printf@plt>
lea    0x1496(%rip),%rdi
call   1030 <printf@plt>
lea    0x1571(%rip),%rdi
call   1030 <printf@plt>
mov    $0x1,%edi
call   1040 <exit@plt>

x86 assembly (clang, -O2):
<usage>:
push   %rax
lea    0xed8(%rip),%rdi
call   1030 <puts@plt>
lea    0xf0e(%rip),%rdi
call   1030 <puts@plt>
lea    0x1082(%rip),%rdi
call   1030 <puts@plt>
lea    0x11b1(%rip),%rdi
call   1030 <puts@plt>
lea    0x12b6(%rip),%rdi
call   1030 <puts@plt>
lea    0x1494(%rip),%rdi
call   1030 <puts@plt>
lea    0x156e(%rip),%rdi
call   1030 <puts@plt>
mov    $0x1,%edi
call   1040 <exit@plt>

LLVM IR (-O0):
@.str = [67 x i8] c"usage: scramble [options] <input file> <output file> [xor string]\0A\00"
@.str.1 = [385 x i8] c"options:\0A\09-fm Archos FM recorder format\0A\09-v2 Archos V2 recorder format\0A\09-ofm Archos Ondio FM recorder format\0A\09-osp Archos Ondio SP format\0A\09-neo SSI Neo format\0A\09-mm=X Archos Multimedia format (X values: A=JBMM, B=AV1xx, C=AV3xx)\0A\09-iriver iRiver format\0A\09-iaudiox5 iAudio X5 format\0A\09-iaudiox5v iAudio X5V format\0A\09-iaudiom5 iAudio M5 format\0A\09-iaudiom3 iAudio M3 format\0A\00"
@.str.2 = [316 x i8] c"\09-ipod3g ipod firmware partition format (3rd Gen)\0A\09-ipod4g ipod firmware partition format (4th Gen, Mini, Nano, Photo/Color)\0A\09-ipod5g ipod firmware partition format (5th Gen - aka Video)\0A\09-creative=X Creative firmware structure format\0A\09 (X values: zvm, zvm60, zenvision\0A\09 zenv, zen\0A\00"
@.str.3 = [274 x i8] c"\09-gigabeat Toshiba Gigabeat F/X format\0A\09-gigabeats Toshiba Gigabeat S format\0A\09-mi4v2 PortalPlayer .mi4 format (revision 010201)\0A\09-mi4v3 PortalPlayer .mi4 format (revision 010301)\0A\09-mi4r Sandisk Rhapsody .mi4 format\0A\09 All mi4 options take two optional arguments:\0A\00"
@.str.4 = [491 x i8] c"\09 -model=XXXX where XXXX is the model id string\0A\09 -type=XXXX where XXXX is a string indicating the \0A\09 type of binary, eg. RBOS, RBBL\0A\09-tcc=X Telechips generic firmware format (X values: sum, crc)\0A\09-add=X Rockbox generic \22add-up\22 checksum format\0A\09 (X values: h100, h120, h140, h300, ipco, nano, ipvd, mn2g\0A\09 ip3g, ip4g, mini, iax5, iam5, iam3, h10, h10_5gb,\0A\09 tpj2, c200, e200, giga, gigs, m100, m500, d2,\0A\00"
@.str.5 = [231 x i8] c"\09 9200, 1630, 6330, ldax, m200, c100, clip, e2v2,\0A\09 m2v4, fuze, c2v2, clv2, y820, y920, y925, x747,\0A\09 747p, x777, nn2g, m244, cli+, fuz2, hd20, hd30,\0A\09 ip6g)\0A\00"
@.str.6 = [63 x i8] c"\0ANo option results in Archos standard player/recorder format.\0A\00"
define void @usage() {
%1 = call i32 @printf(i8* getelementptr inbounds ([67 x i8], [67 x i8]* @.str, i64 0, i64 0))
%2 = call i32 @printf(i8* getelementptr inbounds ([385 x i8], [385 x i8]* @.str.1, i64 0, i64 0))
%3 = call i32 @printf(i8* getelementptr inbounds ([316 x i8], [316 x i8]* @.str.2, i64 0, i64 0))
%4 = call i32 @printf(i8* getelementptr inbounds ([274 x i8], [274 x i8]* @.str.3, i64 0, i64 0))
%5 = call i32 @printf(i8* getelementptr inbounds ([491 x i8], [491 x i8]* @.str.4, i64 0, i64 0))
%6 = call i32 @printf(i8* getelementptr inbounds ([231 x i8], [231 x i8]* @.str.5, i64 0, i64 0))
%7 = call i32 @printf(i8* getelementptr inbounds ([63 x i8], [63 x i8]* @.str.6, i64 0, i64 0))
%8 = call i32 @exit(i32 1)
unreachable
}

LLVM IR (-O2):
@str = [66 x i8] c"usage: scramble [options] <input file> <output file> [xor string]\00"
@str.7 = [384 x i8] c"options:\0A\09-fm Archos FM recorder format\0A\09-v2 Archos V2 recorder format\0A\09-ofm Archos Ondio FM recorder format\0A\09-osp Archos Ondio SP format\0A\09-neo SSI Neo format\0A\09-mm=X Archos Multimedia format (X values: A=JBMM, B=AV1xx, C=AV3xx)\0A\09-iriver iRiver format\0A\09-iaudiox5 iAudio X5 format\0A\09-iaudiox5v iAudio X5V format\0A\09-iaudiom5 iAudio M5 format\0A\09-iaudiom3 iAudio M3 format\00"
@str.8 = [315 x i8] c"\09-ipod3g ipod firmware partition format (3rd Gen)\0A\09-ipod4g ipod firmware partition format (4th Gen, Mini, Nano, Photo/Color)\0A\09-ipod5g ipod firmware partition format (5th Gen - aka Video)\0A\09-creative=X Creative firmware structure format\0A\09 (X values: zvm, zvm60, zenvision\0A\09 zenv, zen\00"
@str.9 = [273 x i8] c"\09-gigabeat Toshiba Gigabeat F/X format\0A\09-gigabeats Toshiba Gigabeat S format\0A\09-mi4v2 PortalPlayer .mi4 format (revision 010201)\0A\09-mi4v3 PortalPlayer .mi4 format (revision 010301)\0A\09-mi4r Sandisk Rhapsody .mi4 format\0A\09 All mi4 options take two optional arguments:\00"
@str.10 = [490 x i8] c"\09 -model=XXXX where XXXX is the model id string\0A\09 -type=XXXX where XXXX is a string indicating the \0A\09 type of binary, eg. RBOS, RBBL\0A\09-tcc=X Telechips generic firmware format (X values: sum, crc)\0A\09-add=X Rockbox generic \22add-up\22 checksum format\0A\09 (X values: h100, h120, h140, h300, ipco, nano, ipvd, mn2g\0A\09 ip3g, ip4g, mini, iax5, iam5, iam3, h10, h10_5gb,\0A\09 tpj2, c200, e200, giga, gigs, m100, m500, d2,\00"
@str.11 = [230 x i8] c"\09 9200, 1630, 6330, ldax, m200, c100, clip, e2v2,\0A\09 m2v4, fuze, c2v2, clv2, y820, y920, y925, x747,\0A\09 747p, x777, nn2g, m244, cli+, fuz2, hd20, hd30,\0A\09 ip6g)\00"
@str.12 = [62 x i8] c"\0ANo option results in Archos standard player/recorder format.\00"
define void @usage() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([66 x i8], [66 x i8]* @str, i64 0, i64 0))
%2 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([384 x i8], [384 x i8]* @str.7, i64 0, i64 0))
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([315 x i8], [315 x i8]* @str.8, i64 0, i64 0))
%4 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([273 x i8], [273 x i8]* @str.9, i64 0, i64 0))
%5 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([490 x i8], [490 x i8]* @str.10, i64 0, i64 0))
%6 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([230 x i8], [230 x i8]* @str.11, i64 0, i64 0))
%7 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([62 x i8], [62 x i8]* @str.12, i64 0, i64 0))
%8 = tail call i32 @exit(i32 1)
unreachable
}