#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 *, ...);
int /*<<< orphan*/ stderr;
void usage(char *s) {
  static char *usage_text =
      " if optional id is not specified, 100 (0x64) is used\n and 8 data bytes "
      "are used to construct a mesage.\n Id and date can be given decimal "
      "(100) or hex 0x64\nOptions:\n-r send message as rtr message.\n-e send "
      "message in extended message format.\n-l load try to reach this bus "
      "load, given in %\n-s n - sleeptime between messages in ms, if not "
      "specified send single message\n-d   - debug On\n       schaltet "
      "zusaetzlich Debugging im Treiber an/aus\n-b baudrate (Standard uses "
      "value of /proc/sys/Can/baud)\n-D dev use /dev/dev/{can0,can1,can2,can3} "
      "(real nodes, std: can1)\n"
      "-t type \n   1 Stresstest für Knoten, Sendet Bursts von kurzen rtr "
      "messages\n   2 transmit bursts of 5 data frames, same ID\n   3 transmit "
      "bursts of 5 data frames, different ID\n     frame 5 contains counter "
      "variable\n   4 as without this option, but incremnts CAN-ID with each "
      "message\n   10 transmit bursts of 9 data frames, used for communication "
      "verification\n   11 transmit -T number of frames as fast as possible, "
      "write(fd, buf, 1)\n      if transmit buffer is full, sleep for -s ms "
      "time. \n      if == 0: don't sleep, poll\n      after every frame the "
      "message-id will be incremented\n   12 same as 11\n      but the "
      "message-id is constant and the databytes will be incremented\n   30 "
      "transmit consecutive messages with the same id\n      -T specifies the "
      "muber of messages in this burst\n-R   reset CAN Controller only, exit() "
      "program after reset\n-T   number of bursts, time distance -s n (for "
      "-t<n>)\n-V   print program version\n\n";
  fprintf(stderr, "usage: %s [options] [id [ byte ..]]\n", s);
  fprintf(stderr, usage_text);
}


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    0x149a(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    0x2ea2(%rip),%rax
mov    (%rax),%edi
mov    0x2ee1(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<usage>:
push   %rbx
mov    %rdi,%rdx
mov    0x2ec5(%rip),%rbx
mov    (%rbx),%edi
lea    0x14a6(%rip),%rsi
xor    %eax,%eax
call   1030 <fprintf@plt>
mov    (%rbx),%edi
lea    0xecc(%rip),%rsi
xor    %eax,%eax
pop    %rbx
jmp    1030 <fprintf@plt>

LLVM IR (-O0):
@usage.usage_text = internal global i8* getelementptr inbounds ([1482 x i8], [1482 x i8]* @.str, i32 0, i32 0)
@.str = [1482 x i8] c" if optional id is not specified, 100 (0x64) is used\0A and 8 data bytes are used to construct a mesage.\0A Id and date can be given decimal (100) or hex 0x64\0AOptions:\0A-r send message as rtr message.\0A-e send message in extended message format.\0A-l load try to reach this bus load, given in %\0A-s n - sleeptime between messages in ms, if not specified send single message\0A-d - debug On\0A schaltet zusaetzlich Debugging im Treiber an/aus\0A-b baudrate (Standard uses value of /proc/sys/Can/baud)\0A-D dev use /dev/dev/{can0,can1,can2,can3} (real nodes, std: can1)\0A-t type \0A 1 Stresstest f\C3\BCr Knoten, Sendet Bursts von kurzen rtr messages\0A 2 transmit bursts of 5 data frames, same ID\0A 3 transmit bursts of 5 data frames, different ID\0A frame 5 contains counter variable\0A 4 as without this option, but incremnts CAN-ID with each message\0A 10 transmit bursts of 9 data frames, used for communication verification\0A 11 transmit -T number of frames as fast as possible, write(fd, buf, 1)\0A if transmit buffer is full, sleep for -s ms time. \0A if == 0: don't sleep, poll\0A after every frame the message-id will be incremented\0A 12 same as 11\0A but the message-id is constant and the databytes will be incremented\0A 30 transmit consecutive messages with the same id\0A -T specifies the muber of messages in this burst\0A-R reset CAN Controller only, exit() program after reset\0A-T number of bursts, time distance -s n (for -t<n>)\0A-V print program version\0A\0A\00"
@stderr = global i32 0
@.str.1 = [37 x i8] c"usage: %s [options] [id [ byte ..]]\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 (i32, i8*, ...) @fprintf(i32 %3, i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str.1, i64 0, i64 0), i8* %4)
%6 = load i32, i32* @stderr
%7 = load i8*, i8** @usage.usage_text
%8 = call i32 (i32, i8*, ...) @fprintf(i32 %6, i8* %7)
ret void
}

LLVM IR (-O2):
@.str = [1482 x i8] c" if optional id is not specified, 100 (0x64) is used\0A and 8 data bytes are used to construct a mesage.\0A Id and date can be given decimal (100) or hex 0x64\0AOptions:\0A-r send message as rtr message.\0A-e send message in extended message format.\0A-l load try to reach this bus load, given in %\0A-s n - sleeptime between messages in ms, if not specified send single message\0A-d - debug On\0A schaltet zusaetzlich Debugging im Treiber an/aus\0A-b baudrate (Standard uses value of /proc/sys/Can/baud)\0A-D dev use /dev/dev/{can0,can1,can2,can3} (real nodes, std: can1)\0A-t type \0A 1 Stresstest f\C3\BCr Knoten, Sendet Bursts von kurzen rtr messages\0A 2 transmit bursts of 5 data frames, same ID\0A 3 transmit bursts of 5 data frames, different ID\0A frame 5 contains counter variable\0A 4 as without this option, but incremnts CAN-ID with each message\0A 10 transmit bursts of 9 data frames, used for communication verification\0A 11 transmit -T number of frames as fast as possible, write(fd, buf, 1)\0A if transmit buffer is full, sleep for -s ms time. \0A if == 0: don't sleep, poll\0A after every frame the message-id will be incremented\0A 12 same as 11\0A but the message-id is constant and the databytes will be incremented\0A 30 transmit consecutive messages with the same id\0A -T specifies the muber of messages in this burst\0A-R reset CAN Controller only, exit() program after reset\0A-T number of bursts, time distance -s n (for -t<n>)\0A-V print program version\0A\0A\00"
@stderr = global i32 0
@.str.1 = [37 x i8] c"usage: %s [options] [id [ byte ..]]\0A\00"
define void @usage(i8* %0) {
%2 = load i32, i32* @stderr
%3 = tail call i32 (i32, i8*, ...) @fprintf(i32 %2, i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str.1, i64 0, i64 0), i8* %0)
%4 = load i32, i32* @stderr
%5 = tail call i32 (i32, i8*, ...) @fprintf(i32 %4, i8* getelementptr inbounds ([1482 x i8], [1482 x i8]* @.str, i64 0, i64 0))
ret void
}