#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 */
struct protocol_header {
  int dummy;
};
struct data {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ print_proto_simple(int, struct protocol_header *,
                                      struct protocol_header *,
                                      struct protocol_header *);
int /*<<< orphan*/ print_simple(int, struct protocol_header *,
                                struct protocol_header *,
                                struct protocol_header *);
void dsp_pkt_simple(int fd, struct protocol_header *datalink_layerph,
                    struct protocol_header *network_layerph,
                    struct protocol_header *transport_layerph,
                    struct data *datagram) {
  print_proto_simple(fd, datalink_layerph, network_layerph, transport_layerph);
  print_simple(fd, datalink_layerph, network_layerph, transport_layerph);
}


x86 assembly (clang, -O0):
<dsp_pkt_simple>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8,-0x28(%rbp)
mov    -0x4(%rbp),%edi
mov    -0x10(%rbp),%rsi
mov    -0x18(%rbp),%rdx
mov    -0x20(%rbp),%rcx
call   1030 <print_proto_simple@plt>
mov    -0x4(%rbp),%edi
mov    -0x10(%rbp),%rsi
mov    -0x18(%rbp),%rdx
mov    -0x20(%rbp),%rcx
call   1040 <print_simple@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<dsp_pkt_simple>:
push   %rbp
push   %r15
push   %r14
push   %rbx
push   %rax
mov    %rcx,%r14
mov    %rdx,%r15
mov    %rsi,%rbx
mov    %edi,%ebp
call   1030 <print_proto_simple@plt>
mov    %ebp,%edi
mov    %rbx,%rsi
mov    %r15,%rdx
mov    %r14,%rcx
add    $0x8,%rsp
pop    %rbx
pop    %r14
pop    %r15
pop    %rbp
jmp    1040 <print_simple@plt>

LLVM IR (-O0):
%struct.protocol_header = type { i32 }
%struct.data = type { i32 }
define void @dsp_pkt_simple(i32 %0, %struct.protocol_header* %1, %struct.protocol_header* %2, %struct.protocol_header* %3, %struct.data* %4) {
%6 = alloca i32
%7 = alloca %struct.protocol_header*
%8 = alloca %struct.protocol_header*
%9 = alloca %struct.protocol_header*
%10 = alloca %struct.data*
store i32 %0, i32* %6
store %struct.protocol_header* %1, %struct.protocol_header** %7
store %struct.protocol_header* %2, %struct.protocol_header** %8
store %struct.protocol_header* %3, %struct.protocol_header** %9
store %struct.data* %4, %struct.data** %10
%11 = load i32, i32* %6
%12 = load %struct.protocol_header*, %struct.protocol_header** %7
%13 = load %struct.protocol_header*, %struct.protocol_header** %8
%14 = load %struct.protocol_header*, %struct.protocol_header** %9
%15 = call i32 @print_proto_simple(i32 %11, %struct.protocol_header* %12, %struct.protocol_header* %13, %struct.protocol_header* %14)
%16 = load i32, i32* %6
%17 = load %struct.protocol_header*, %struct.protocol_header** %7
%18 = load %struct.protocol_header*, %struct.protocol_header** %8
%19 = load %struct.protocol_header*, %struct.protocol_header** %9
%20 = call i32 @print_simple(i32 %16, %struct.protocol_header* %17, %struct.protocol_header* %18, %struct.protocol_header* %19)
ret void
}

LLVM IR (-O2):
%struct.protocol_header = type { i32 }
%struct.data = type { i32 }
define void @dsp_pkt_simple(i32 %0, %struct.protocol_header* %1, %struct.protocol_header* %2, %struct.protocol_header* %3, %struct.data* nocapture readnone %4) {
%6 = tail call i32 @print_proto_simple(i32 %0, %struct.protocol_header* %1, %struct.protocol_header* %2, %struct.protocol_header* %3)
%7 = tail call i32 @print_simple(i32 %0, %struct.protocol_header* %1, %struct.protocol_header* %2, %struct.protocol_header* %3)
ret void
}