#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*/ free(char *);
char *getBracketParam();
int getStringDimension(char *);
char getTexChar();
int /*<<< orphan*/ ungetTexChar(char);
int getSlashSlashParam(void) {
  char cThis, *vertical_space;
  int height = 0;
  cThis = getTexChar();
  if (cThis != '*')
    ungetTexChar(cThis);
  vertical_space = getBracketParam();
  if (vertical_space) {
    height = getStringDimension(vertical_space);
    free(vertical_space);
  }
  return height;
}


x86 assembly (clang, -O0):
<getSlashSlashParam>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x14(%rbp)
mov    $0x0,%al
call   1050 <getTexChar@plt>
mov    %al,-0x1(%rbp)
movsbl -0x1(%rbp),%eax
cmp    $0x2a,%eax
je     117f <getSlashSlashParam+0x2f>
movsbl -0x1(%rbp),%edi
call   1040 <ungetTexChar@plt>
mov    $0x0,%al
call   1060 <getBracketParam@plt>
mov    %rax,-0x10(%rbp)
cmpq   $0x0,-0x10(%rbp)
je     11aa <getSlashSlashParam+0x5a>
mov    -0x10(%rbp),%rdi
call   1070 <getStringDimension@plt>
mov    %eax,-0x14(%rbp)
mov    -0x10(%rbp),%rdi
call   1030 <free@plt>
mov    -0x14(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<getSlashSlashParam>:
push   %rbp
push   %rbx
push   %rax
xor    %eax,%eax
call   1050 <getTexChar@plt>
cmp    $0x2a,%al
je     1166 <getSlashSlashParam+0x16>
movsbl %al,%edi
call   1040 <ungetTexChar@plt>
xor    %eax,%eax
call   1060 <getBracketParam@plt>
test   %rax,%rax
je     118b <getSlashSlashParam+0x3b>
mov    %rax,%rbx
mov    %rax,%rdi
call   1070 <getStringDimension@plt>
mov    %eax,%ebp
mov    %rbx,%rdi
call   1030 <free@plt>
mov    %ebp,%eax
jmp    118d <getSlashSlashParam+0x3d>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

LLVM IR (-O0):
define i32 @getSlashSlashParam() {
%1 = alloca i8
%2 = alloca i8*
%3 = alloca i32
store i32 0, i32* %3
%4 = call signext i8 (...) @getTexChar()
store i8 %4, i8* %1
%5 = load i8, i8* %1
%6 = sext i8 %5 to i32
%7 = icmp ne i32 %6, 42
br i1 %7, label %8, label %11
8: ; preds = %0
%9 = load i8, i8* %1
%10 = call i32 @ungetTexChar(i8 signext %9)
br label %11
11: ; preds = %8, %0
%12 = call i8* (...) @getBracketParam()
store i8* %12, i8** %2
%13 = load i8*, i8** %2
%14 = icmp ne i8* %13, null
br i1 %14, label %15, label %20
15: ; preds = %11
%16 = load i8*, i8** %2
%17 = call i32 @getStringDimension(i8* %16)
store i32 %17, i32* %3
%18 = load i8*, i8** %2
%19 = call i32 @free(i8* %18)
br label %20
20: ; preds = %15, %11
%21 = load i32, i32* %3
ret i32 %21
}

LLVM IR (-O2):
define i32 @getSlashSlashParam() {
%1 = tail call signext i8 (...) @getTexChar()
%2 = icmp eq i8 %1, 42
br i1 %2, label %5, label %3
3: ; preds = %0
%4 = tail call i32 @ungetTexChar(i8 signext %1)
br label %5
5: ; preds = %3, %0
%6 = tail call i8* (...) @getBracketParam()
%7 = icmp eq i8* %6, null
br i1 %7, label %11, label %8
8: ; preds = %5
%9 = tail call i32 @getStringDimension(i8* %6)
%10 = tail call i32 @free(i8* %6)
br label %11
11: ; preds = %8, %5
%12 = phi i32 [ %9, %8 ], [ 0, %5 ]
ret i32 %12
}