#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 uint8_t;

/* Variables and functions */
void port_init() {
  *(volatile uint8_t *)0x5000 = 0x00;
  *(volatile uint8_t *)0x5002 = 0xFF;
  *(volatile uint8_t *)0x5003 = 0xFF;
  *(volatile uint8_t *)0x5004 = 0x00;
  *(volatile uint8_t *)0x5005 = 0x00;
  *(volatile uint8_t *)0x5007 = 0xFF;
  *(volatile uint8_t *)0x5008 = 0xFF;
  *(volatile uint8_t *)0x5009 = 0x00;
  *(volatile uint8_t *)0x500A = 0x00;
  *(volatile uint8_t *)0x500C = 0xFF;
  *(volatile uint8_t *)0x500D = 0xFF;
  *(volatile uint8_t *)0x500E = 0x00;
  *(volatile uint8_t *)0x500F = 0x00;
  *(volatile uint8_t *)0x5011 = 0xFF;
  *(volatile uint8_t *)0x5012 = 0xFF;
  *(volatile uint8_t *)0x5013 = 0x00;
}


x86 assembly (clang, -O0):
<port_init>:
push   %rbp
mov    %rsp,%rbp
mov    $0x5000,%eax
movl   $0x0,(%rax)
mov    $0x5002,%eax
movl   $0xff,(%rax)
mov    $0x5003,%eax
movl   $0xff,(%rax)
mov    $0x5004,%eax
movl   $0x0,(%rax)
mov    $0x5005,%eax
movl   $0x0,(%rax)
mov    $0x5007,%eax
movl   $0xff,(%rax)
mov    $0x5008,%eax
movl   $0xff,(%rax)
mov    $0x5009,%eax
movl   $0x0,(%rax)
mov    $0x500a,%eax
movl   $0x0,(%rax)
mov    $0x500c,%eax
movl   $0xff,(%rax)
mov    $0x500d,%eax
movl   $0xff,(%rax)
mov    $0x500e,%eax
movl   $0x0,(%rax)
mov    $0x500f,%eax
movl   $0x0,(%rax)
mov    $0x5011,%eax
movl   $0xff,(%rax)
mov    $0x5012,%eax
movl   $0xff,(%rax)
mov    $0x5013,%eax
movl   $0x0,(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<port_init>:
movl   $0x0,0x5000
movl   $0xff,0x5002
movl   $0xff,0x5003
movl   $0x0,0x5004
movl   $0x0,0x5005
movl   $0xff,0x5007
movl   $0xff,0x5008
movl   $0x0,0x5009
movl   $0x0,0x500a
movl   $0xff,0x500c
movl   $0xff,0x500d
movl   $0x0,0x500e
movl   $0x0,0x500f
movl   $0xff,0x5011
movl   $0xff,0x5012
movl   $0x0,0x5013
ret

LLVM IR (-O0):
define void @port_init() {
store volatile i32 0, i32* inttoptr (i64 20480 to i32*)
store volatile i32 255, i32* inttoptr (i64 20482 to i32*)
store volatile i32 255, i32* inttoptr (i64 20483 to i32*)
store volatile i32 0, i32* inttoptr (i64 20484 to i32*)
store volatile i32 0, i32* inttoptr (i64 20485 to i32*)
store volatile i32 255, i32* inttoptr (i64 20487 to i32*)
store volatile i32 255, i32* inttoptr (i64 20488 to i32*)
store volatile i32 0, i32* inttoptr (i64 20489 to i32*)
store volatile i32 0, i32* inttoptr (i64 20490 to i32*)
store volatile i32 255, i32* inttoptr (i64 20492 to i32*)
store volatile i32 255, i32* inttoptr (i64 20493 to i32*)
store volatile i32 0, i32* inttoptr (i64 20494 to i32*)
store volatile i32 0, i32* inttoptr (i64 20495 to i32*)
store volatile i32 255, i32* inttoptr (i64 20497 to i32*)
store volatile i32 255, i32* inttoptr (i64 20498 to i32*)
store volatile i32 0, i32* inttoptr (i64 20499 to i32*)
ret void
}

LLVM IR (-O2):
define void @port_init() {
store volatile i32 0, i32* inttoptr (i64 20480 to i32*)
store volatile i32 255, i32* inttoptr (i64 20482 to i32*)
store volatile i32 255, i32* inttoptr (i64 20483 to i32*)
store volatile i32 0, i32* inttoptr (i64 20484 to i32*)
store volatile i32 0, i32* inttoptr (i64 20485 to i32*)
store volatile i32 255, i32* inttoptr (i64 20487 to i32*)
store volatile i32 255, i32* inttoptr (i64 20488 to i32*)
store volatile i32 0, i32* inttoptr (i64 20489 to i32*)
store volatile i32 0, i32* inttoptr (i64 20490 to i32*)
store volatile i32 255, i32* inttoptr (i64 20492 to i32*)
store volatile i32 255, i32* inttoptr (i64 20493 to i32*)
store volatile i32 0, i32* inttoptr (i64 20494 to i32*)
store volatile i32 0, i32* inttoptr (i64 20495 to i32*)
store volatile i32 255, i32* inttoptr (i64 20497 to i32*)
store volatile i32 255, i32* inttoptr (i64 20498 to i32*)
store volatile i32 0, i32* inttoptr (i64 20499 to i32*)
ret void
}