#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*/ array;

/* Variables and functions */
int EXIT_SUCCESS;
int /*<<< orphan*/ printf(char *, ...);
int strlen(char *);
int main(int argc, char *argv[]) {
  char *array[] = {"campobasso", "roma",    "napoli", "venezia",
                   "verona",     "torino",  "milano", "genova",
                   "palermo",    "catania", "bari",   "firenze"};
  int len = sizeof(array) / sizeof(char *);
  for (int x = 0; x < len; x++) {
    for (int y = 0; y <= strlen(array[x]); y++)
      printf("%c", array[x][y]);
    printf("\n");
  }
  return (EXIT_SUCCESS);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x80,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
lea    -0x70(%rbp),%rdi
lea    0x2c5c(%rip),%rsi
mov    $0x60,%edx
call   1050 <memcpy@plt>
movl   $0xc,-0x74(%rbp)
movl   $0x0,-0x78(%rbp)
mov    -0x78(%rbp),%eax
cmp    -0x74(%rbp),%eax
jge    11e9 <main+0xb9>
movl   $0x0,-0x7c(%rbp)
mov    -0x7c(%rbp),%eax
mov    %eax,-0x80(%rbp)
movslq -0x78(%rbp),%rax
mov    -0x70(%rbp,%rax,8),%rdi
call   1030 <strlen@plt>
mov    %eax,%ecx
mov    -0x80(%rbp),%eax
cmp    %ecx,%eax
jg     11cd <main+0x9d>
movslq -0x78(%rbp),%rax
mov    -0x70(%rbp,%rax,8),%rax
movslq -0x7c(%rbp),%rcx
movsbl (%rax,%rcx,1),%esi
lea    0xea0(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x7c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x7c(%rbp)
jmp    117f <main+0x4f>
lea    0xe87(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x78(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x78(%rbp)
jmp    116c <main+0x3c>
mov    0x2de8(%rip),%rax
mov    (%rax),%eax
add    $0x80,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r15
push   %r14
push   %r12
push   %rbx
push   %rax
xor    %r14d,%r14d
lea    0x2c7e(%rip),%r15
jmp    1154 <main+0x34>
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
mov    $0xa,%edi
call   1030 <putchar@plt>
add    $0x1,%r14
cmp    $0xc,%r14
je     1190 <main+0x70>
mov    (%r15,%r14,8),%r12
mov    %r12,%rdi
call   1040 <strlen@plt>
test   %eax,%eax
js     1140 <main+0x20>
mov    $0xffffffffffffffff,%rbx
nopl   0x0(%rax,%rax,1)
movsbl 0x1(%r12,%rbx,1),%edi
call   1030 <putchar@plt>
mov    %r12,%rdi
call   1040 <strlen@plt>
cltq
add    $0x1,%rbx
cmp    %rax,%rbx
jl     1170 <main+0x50>
jmp    1140 <main+0x20>
mov    0x2e41(%rip),%rax
mov    (%rax),%eax
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
@.str = [11 x i8] c"campobasso\00"
@.str.1 = [5 x i8] c"roma\00"
@.str.2 = [7 x i8] c"napoli\00"
@.str.3 = [8 x i8] c"venezia\00"
@.str.4 = [7 x i8] c"verona\00"
@.str.5 = [7 x i8] c"torino\00"
@.str.6 = [7 x i8] c"milano\00"
@.str.7 = [7 x i8] c"genova\00"
@.str.8 = [8 x i8] c"palermo\00"
@.str.9 = [8 x i8] c"catania\00"
@.str.10 = [5 x i8] c"bari\00"
@.str.11 = [8 x i8] c"firenze\00"
@__const.main.array = [12 x i8*] [i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i32 0, i32 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.2, i32 0, i32 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.3, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.4, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.5, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.6, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.7, i32 0, i32 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.8, i32 0, i32 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.9, i32 0, i32 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.10, i32 0, i32 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.11, i32 0, i32 0)]
@.str.12 = [3 x i8] c"%c\00"
@.str.13 = [2 x i8] c"\0A\00"
@EXIT_SUCCESS = global i32 0
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca [12 x i8*]
%7 = alloca i32
%8 = alloca i32
%9 = alloca i32
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%10 = bitcast [12 x i8*]* %6 to i8*
store i32 12, i32* %7
store i32 0, i32* %8
br label %11
11: ; preds = %40, %2
%12 = load i32, i32* %8
%13 = load i32, i32* %7
%14 = icmp slt i32 %12, %13
br i1 %14, label %15, label %43
15: ; preds = %11
store i32 0, i32* %9
br label %16
16: ; preds = %35, %15
%17 = load i32, i32* %9
%18 = load i32, i32* %8
%19 = sext i32 %18 to i64
%20 = getelementptr inbounds [12 x i8*], [12 x i8*]* %6, i64 0, i64 %19
%21 = load i8*, i8** %20
%22 = call i32 @strlen(i8* %21)
%23 = icmp sle i32 %17, %22
br i1 %23, label %24, label %38
24: ; preds = %16
%25 = load i32, i32* %8
%26 = sext i32 %25 to i64
%27 = getelementptr inbounds [12 x i8*], [12 x i8*]* %6, i64 0, i64 %26
%28 = load i8*, i8** %27
%29 = load i32, i32* %9
%30 = sext i32 %29 to i64
%31 = getelementptr inbounds i8, i8* %28, i64 %30
%32 = load i8, i8* %31
%33 = sext i8 %32 to i32
%34 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.12, i64 0, i64 0), i32 %33)
br label %35
35: ; preds = %24
%36 = load i32, i32* %9
%37 = add nsw i32 %36, 1
store i32 %37, i32* %9
br label %16
38: ; preds = %16
%39 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.13, i64 0, i64 0))
br label %40
40: ; preds = %38
%41 = load i32, i32* %8
%42 = add nsw i32 %41, 1
store i32 %42, i32* %8
br label %11
43: ; preds = %11
%44 = load i32, i32* @EXIT_SUCCESS
ret i32 %44
}

LLVM IR (-O2):
@.str = [11 x i8] c"campobasso\00"
@.str.1 = [5 x i8] c"roma\00"
@.str.2 = [7 x i8] c"napoli\00"
@.str.3 = [8 x i8] c"venezia\00"
@.str.4 = [7 x i8] c"verona\00"
@.str.5 = [7 x i8] c"torino\00"
@.str.6 = [7 x i8] c"milano\00"
@.str.7 = [7 x i8] c"genova\00"
@.str.8 = [8 x i8] c"palermo\00"
@.str.9 = [8 x i8] c"catania\00"
@.str.10 = [5 x i8] c"bari\00"
@.str.11 = [8 x i8] c"firenze\00"
@__const.main.array = [12 x i8*] [i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i32 0, i32 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.2, i32 0, i32 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.3, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.4, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.5, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.6, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.7, i32 0, i32 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.8, i32 0, i32 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.9, i32 0, i32 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.10, i32 0, i32 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.11, i32 0, i32 0)]
@EXIT_SUCCESS = global i32 0
define i32 @main(i32 %0, i8** nocapture readnone %1) {
br label %3
3: ; preds = %2, %11
%4 = phi i64 [ 0, %2 ], [ %13, %11 ]
%5 = getelementptr inbounds [12 x i8*], [12 x i8*]* @__const.main.array, i64 0, i64 %4
%6 = load i8*, i8** %5
%7 = tail call i32 @strlen(i8* %6)
%8 = icmp slt i32 %7, 0
br i1 %8, label %11, label %15
9: ; preds = %11
%10 = load i32, i32* @EXIT_SUCCESS
ret i32 %10
11: ; preds = %15, %3
%12 = tail call i32 @putchar(i32 10)
%13 = add nuw nsw i64 %4, 1
%14 = icmp eq i64 %13, 12
br i1 %14, label %9, label %3
15: ; preds = %3, %15
%16 = phi i64 [ %21, %15 ], [ 0, %3 ]
%17 = getelementptr inbounds i8, i8* %6, i64 %16
%18 = load i8, i8* %17
%19 = sext i8 %18 to i32
%20 = tail call i32 @putchar(i32 %19)
%21 = add nuw nsw i64 %16, 1
%22 = tail call i32 @strlen(i8* %6)
%23 = sext i32 %22 to i64
%24 = icmp slt i64 %16, %23
br i1 %24, label %15, label %11
}