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

/* Variables and functions */
int /*<<< orphan*/ free(int /*<<< orphan*/ ******);
void deleteAdjMatrix(struct Edge **aM) {
  int i;
  for (i = 0; i < 9; i++)
    free(aM[i]);
  free(aM);
}


x86 assembly (clang, -O0):
<deleteAdjMatrix>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
movl   $0x0,-0xc(%rbp)
cmpl   $0x9,-0xc(%rbp)
jge    114c <deleteAdjMatrix+0x3c>
mov    -0x8(%rbp),%rax
movslq -0xc(%rbp),%rcx
mov    (%rax,%rcx,8),%rdi
call   1030 <free@plt>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    1123 <deleteAdjMatrix+0x13>
mov    -0x8(%rbp),%rdi
call   1030 <free@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<deleteAdjMatrix>:
push   %rbx
mov    %rdi,%rbx
mov    (%rdi),%rdi
call   1030 <free@plt>
mov    0x8(%rbx),%rdi
call   1030 <free@plt>
mov    0x10(%rbx),%rdi
call   1030 <free@plt>
mov    0x18(%rbx),%rdi
call   1030 <free@plt>
mov    0x20(%rbx),%rdi
call   1030 <free@plt>
mov    0x28(%rbx),%rdi
call   1030 <free@plt>
mov    0x30(%rbx),%rdi
call   1030 <free@plt>
mov    0x38(%rbx),%rdi
call   1030 <free@plt>
mov    0x40(%rbx),%rdi
call   1030 <free@plt>
mov    %rbx,%rdi
pop    %rbx
jmp    1030 <free@plt>

LLVM IR (-O0):
%struct.Edge = type opaque
define void @deleteAdjMatrix(%struct.Edge** %0) {
%2 = alloca %struct.Edge**
%3 = alloca i32
store %struct.Edge** %0, %struct.Edge*** %2
store i32 0, i32* %3
br label %4
4: ; preds = %15, %1
%5 = load i32, i32* %3
%6 = icmp slt i32 %5, 9
br i1 %6, label %7, label %18
7: ; preds = %4
%8 = load %struct.Edge**, %struct.Edge*** %2
%9 = load i32, i32* %3
%10 = sext i32 %9 to i64
%11 = getelementptr inbounds %struct.Edge*, %struct.Edge** %8, i64 %10
%12 = load %struct.Edge*, %struct.Edge** %11
%13 = bitcast %struct.Edge* %12 to i32******
%14 = call i32 @free(i32****** %13)
br label %15
15: ; preds = %7
%16 = load i32, i32* %3
%17 = add nsw i32 %16, 1
store i32 %17, i32* %3
br label %4
18: ; preds = %4
%19 = load %struct.Edge**, %struct.Edge*** %2
%20 = bitcast %struct.Edge** %19 to i32******
%21 = call i32 @free(i32****** %20)
ret void
}

LLVM IR (-O2):
%struct.Edge = type opaque
define void @deleteAdjMatrix(%struct.Edge** nocapture %0) {
%2 = bitcast %struct.Edge** %0 to i32*******
%3 = load i32******, i32******* %2
%4 = tail call i32 @free(i32****** %3)
%5 = getelementptr inbounds %struct.Edge*, %struct.Edge** %0, i64 1
%6 = bitcast %struct.Edge** %5 to i32*******
%7 = load i32******, i32******* %6
%8 = tail call i32 @free(i32****** %7)
%9 = getelementptr inbounds %struct.Edge*, %struct.Edge** %0, i64 2
%10 = bitcast %struct.Edge** %9 to i32*******
%11 = load i32******, i32******* %10
%12 = tail call i32 @free(i32****** %11)
%13 = getelementptr inbounds %struct.Edge*, %struct.Edge** %0, i64 3
%14 = bitcast %struct.Edge** %13 to i32*******
%15 = load i32******, i32******* %14
%16 = tail call i32 @free(i32****** %15)
%17 = getelementptr inbounds %struct.Edge*, %struct.Edge** %0, i64 4
%18 = bitcast %struct.Edge** %17 to i32*******
%19 = load i32******, i32******* %18
%20 = tail call i32 @free(i32****** %19)
%21 = getelementptr inbounds %struct.Edge*, %struct.Edge** %0, i64 5
%22 = bitcast %struct.Edge** %21 to i32*******
%23 = load i32******, i32******* %22
%24 = tail call i32 @free(i32****** %23)
%25 = getelementptr inbounds %struct.Edge*, %struct.Edge** %0, i64 6
%26 = bitcast %struct.Edge** %25 to i32*******
%27 = load i32******, i32******* %26
%28 = tail call i32 @free(i32****** %27)
%29 = getelementptr inbounds %struct.Edge*, %struct.Edge** %0, i64 7
%30 = bitcast %struct.Edge** %29 to i32*******
%31 = load i32******, i32******* %30
%32 = tail call i32 @free(i32****** %31)
%33 = getelementptr inbounds %struct.Edge*, %struct.Edge** %0, i64 8
%34 = bitcast %struct.Edge** %33 to i32*******
%35 = load i32******, i32******* %34
%36 = tail call i32 @free(i32****** %35)
%37 = bitcast %struct.Edge** %0 to i32******
%38 = tail call i32 @free(i32****** %37)
ret void
}