#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 */
typedef int /*<<< orphan*/ ssize_t;

/* Variables and functions */
int /*<<< orphan*/ handle(char);
int /*<<< orphan*/ send_real(int, char *, size_t, int, void *, int);
ssize_t send(int fd, char *m, size_t len, int x, void *y, int z) {
  if (len == 4 && m && ((*m) > 0x1d)) {
    handle(*m);
  }
  return send_real(fd, m, len, x, y, z);
}


x86 assembly (clang, -O0):
<send>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %ecx,-0x1c(%rbp)
mov    %r8,-0x28(%rbp)
mov    %r9d,-0x2c(%rbp)
cmpq   $0x4,-0x18(%rbp)
jne    1170 <send+0x50>
cmpq   $0x0,-0x10(%rbp)
je     1170 <send+0x50>
mov    -0x10(%rbp),%rax
movsbl (%rax),%eax
cmp    $0x1d,%eax
jle    1170 <send+0x50>
mov    -0x10(%rbp),%rax
movsbl (%rax),%edi
call   1030 <handle@plt>
mov    -0x4(%rbp),%edi
mov    -0x10(%rbp),%rsi
mov    -0x18(%rbp),%rdx
mov    -0x1c(%rbp),%ecx
mov    -0x28(%rbp),%r8
mov    -0x2c(%rbp),%r9d
call   1040 <send_real@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<send>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
push   %rax
mov    %r9d,%r14d
mov    %r8,%r15
mov    %ecx,%r12d
mov    %rdx,%rbx
mov    %rsi,%rbp
mov    %edi,%r13d
test   %rsi,%rsi
je     1157 <send+0x37>
cmp    $0x4,%rbx
jne    1157 <send+0x37>
mov    0x0(%rbp),%al
cmp    $0x1e,%al
jl     1157 <send+0x37>
movsbl %al,%edi
call   1030 <handle@plt>
mov    %r13d,%edi
mov    %rbp,%rsi
mov    %rbx,%rdx
mov    %r12d,%ecx
mov    %r15,%r8
mov    %r14d,%r9d
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
jmp    1040 <send_real@plt>

LLVM IR (-O0):
define i32 @send(i32 %0, i8* %1, i64 %2, i32 %3, i8* %4, i32 %5) {
%7 = alloca i32
%8 = alloca i8*
%9 = alloca i64
%10 = alloca i32
%11 = alloca i8*
%12 = alloca i32
store i32 %0, i32* %7
store i8* %1, i8** %8
store i64 %2, i64* %9
store i32 %3, i32* %10
store i8* %4, i8** %11
store i32 %5, i32* %12
%13 = load i64, i64* %9
%14 = icmp eq i64 %13, 4
br i1 %14, label %15, label %27
15: ; preds = %6
%16 = load i8*, i8** %8
%17 = icmp ne i8* %16, null
br i1 %17, label %18, label %27
18: ; preds = %15
%19 = load i8*, i8** %8
%20 = load i8, i8* %19
%21 = sext i8 %20 to i32
%22 = icmp sgt i32 %21, 29
br i1 %22, label %23, label %27
23: ; preds = %18
%24 = load i8*, i8** %8
%25 = load i8, i8* %24
%26 = call i32 @handle(i8 signext %25)
br label %27
27: ; preds = %23, %18, %15, %6
%28 = load i32, i32* %7
%29 = load i8*, i8** %8
%30 = load i64, i64* %9
%31 = load i32, i32* %10
%32 = load i8*, i8** %11
%33 = load i32, i32* %12
%34 = call i32 @send_real(i32 %28, i8* %29, i64 %30, i32 %31, i8* %32, i32 %33)
ret i32 %34
}

LLVM IR (-O2):
define i32 @send(i32 %0, i8* %1, i64 %2, i32 %3, i8* %4, i32 %5) {
%7 = icmp eq i64 %2, 4
%8 = icmp ne i8* %1, null
%9 = and i1 %8, %7
br i1 %9, label %10, label %15
10: ; preds = %6
%11 = load i8, i8* %1
%12 = icmp sgt i8 %11, 29
br i1 %12, label %13, label %15
13: ; preds = %10
%14 = tail call i32 @handle(i8 signext %11)
br label %15
15: ; preds = %13, %10, %6
%16 = tail call i32 @send_real(i32 %0, i8* %1, i64 %2, i32 %3, i8* %4, i32 %5)
ret i32 %16
}