print_poly3(poly) double poly[25][25][25];
{
  int ord1, ord2, ord3;
  int i, j, k;
  order_poly3(poly, &ord1, &ord2, &ord3);
  for (k = 0; k <= ord3; ++k) {
    for (j = 0; j <= ord2; ++j) {
      for (i = 0; i <= ord1; ++i)
        printf("%f\t", poly[i][j][k]);
      printf("\n");
    }
    printf("\n");
  }
}


x86 assembly (clang, -O0):
<print_poly3>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %rdi,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
lea    -0x14(%rbp),%rsi
lea    -0x18(%rbp),%rdx
lea    -0x1c(%rbp),%rcx
mov    $0x0,%al
call   1040 <order_poly3@plt>
movl   $0x0,-0x28(%rbp)
mov    -0x28(%rbp),%eax
cmp    -0x1c(%rbp),%eax
jg     11f9 <print_poly3+0xd9>
movl   $0x0,-0x24(%rbp)
mov    -0x24(%rbp),%eax
cmp    -0x18(%rbp),%eax
jg     11dd <print_poly3+0xbd>
movl   $0x0,-0x20(%rbp)
mov    -0x20(%rbp),%eax
cmp    -0x14(%rbp),%eax
jg     11c1 <print_poly3+0xa1>
mov    -0x10(%rbp),%rax
movslq -0x20(%rbp),%rcx
imul   $0x1388,%rcx,%rcx
add    %rcx,%rax
movslq -0x24(%rbp),%rcx
imul   $0xc8,%rcx,%rcx
add    %rcx,%rax
movslq -0x28(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
lea    0xe54(%rip),%rdi
mov    $0x1,%al
call   1030 <printf@plt>
mov    -0x20(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x20(%rbp)
jmp    1170 <print_poly3+0x50>
lea    0xe3c(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x24(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x24(%rbp)
jmp    115d <print_poly3+0x3d>
lea    0xe20(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x28(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x28(%rbp)
jmp    114a <print_poly3+0x2a>
mov    -0x4(%rbp),%eax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<print_poly3>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x18,%rsp
mov    %rdi,%r15
lea    0xc(%rsp),%rsi
lea    0x8(%rsp),%rdx
lea    0x4(%rsp),%rcx
xor    %eax,%eax
call   1050 <order_poly3@plt>
cmpl   $0x0,0x4(%rsp)
js     1217 <print_poly3+0xe7>
xor    %eax,%eax
lea    0xe95(%rip),%rbx
jmp    1195 <print_poly3+0x65>
nopl   (%rax)
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    0x10(%rsp),%rdx
lea    0x1(%rdx),%rax
movslq 0x4(%rsp),%rcx
add    $0x8,%r15
cmp    %rcx,%rdx
jge    1217 <print_poly3+0xe7>
mov    %rax,0x10(%rsp)
cmpl   $0x0,0x8(%rsp)
js     1170 <print_poly3+0x40>
mov    %r15,%r14
xor    %r13d,%r13d
jmp    11d2 <print_poly3+0xa2>
nopl   0x0(%rax)
mov    $0xa,%edi
call   1030 <putchar@plt>
lea    0x1(%r13),%rax
movslq 0x8(%rsp),%rcx
add    $0xc8,%r14
cmp    %rcx,%r13
mov    %rax,%r13
jge    1170 <print_poly3+0x40>
cmpl   $0x0,0xc(%rsp)
js     11b0 <print_poly3+0x80>
mov    $0xffffffffffffffff,%rbp
mov    %r14,%r12
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
movsd  (%r12),%xmm0
mov    %rbx,%rdi
mov    $0x1,%al
call   1040 <printf@plt>
movslq 0xc(%rsp),%rax
add    $0x1,%rbp
add    $0x1388,%r12
cmp    %rax,%rbp
jl     11f0 <print_poly3+0xc0>
jmp    11b0 <print_poly3+0x80>
add    $0x18,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [4 x i8] c"%f\09\00"
@.str.1 = [2 x i8] c"\0A\00"
define i32 @print_poly3([25 x [25 x double]]* %0) {
%2 = alloca i32
%3 = alloca [25 x [25 x double]]*
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
%9 = alloca i32
store [25 x [25 x double]]* %0, [25 x [25 x double]]** %3
%10 = load [25 x [25 x double]]*, [25 x [25 x double]]** %3
%11 = call i32 ([25 x [25 x double]]*, i32*, i32*, i32*, ...) bitcast (i32 (...)* @order_poly3 to i32 ([25 x [25 x double]]*, i32*, i32*, i32*, ...)*)([25 x [25 x double]]* %10, i32* %4, i32* %5, i32* %6)
store i32 0, i32* %9
br label %12
12: ; preds = %49, %1
%13 = load i32, i32* %9
%14 = load i32, i32* %6
%15 = icmp sle i32 %13, %14
br i1 %15, label %16, label %52
16: ; preds = %12
store i32 0, i32* %8
br label %17
17: ; preds = %44, %16
%18 = load i32, i32* %8
%19 = load i32, i32* %5
%20 = icmp sle i32 %18, %19
br i1 %20, label %21, label %47
21: ; preds = %17
store i32 0, i32* %7
br label %22
22: ; preds = %39, %21
%23 = load i32, i32* %7
%24 = load i32, i32* %4
%25 = icmp sle i32 %23, %24
br i1 %25, label %26, label %42
26: ; preds = %22
%27 = load [25 x [25 x double]]*, [25 x [25 x double]]** %3
%28 = load i32, i32* %7
%29 = sext i32 %28 to i64
%30 = getelementptr inbounds [25 x [25 x double]], [25 x [25 x double]]* %27, i64 %29
%31 = load i32, i32* %8
%32 = sext i32 %31 to i64
%33 = getelementptr inbounds [25 x [25 x double]], [25 x [25 x double]]* %30, i64 0, i64 %32
%34 = load i32, i32* %9
%35 = sext i32 %34 to i64
%36 = getelementptr inbounds [25 x double], [25 x double]* %33, i64 0, i64 %35
%37 = load double, double* %36
%38 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), double %37)
br label %39
39: ; preds = %26
%40 = load i32, i32* %7
%41 = add nsw i32 %40, 1
store i32 %41, i32* %7
br label %22
42: ; preds = %22
%43 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
br label %44
44: ; preds = %42
%45 = load i32, i32* %8
%46 = add nsw i32 %45, 1
store i32 %46, i32* %8
br label %17
47: ; preds = %17
%48 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
br label %49
49: ; preds = %47
%50 = load i32, i32* %9
%51 = add nsw i32 %50, 1
store i32 %51, i32* %9
br label %12
52: ; preds = %12
%53 = load i32, i32* %2
ret i32 %53
}

LLVM IR (-O2):
@.str = [4 x i8] c"%f\09\00"
define i32 @print_poly3([25 x [25 x double]]* %0) {
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
%5 = bitcast i32* %2 to i8*
%6 = bitcast i32* %3 to i8*
%7 = bitcast i32* %4 to i8*
%8 = call i32 ([25 x [25 x double]]*, i32*, i32*, i32*, ...) bitcast (i32 (...)* @order_poly3 to i32 ([25 x [25 x double]]*, i32*, i32*, i32*, ...)*)([25 x [25 x double]]* %0, i32* %2, i32* %3, i32* %4)
%9 = load i32, i32* %4
%10 = icmp slt i32 %9, 0
br i1 %10, label %40, label %11
11: ; preds = %1, %34
%12 = phi i64 [ %36, %34 ], [ 0, %1 ]
%13 = load i32, i32* %3
%14 = icmp slt i32 %13, 0
br i1 %14, label %34, label %15
15: ; preds = %11, %28
%16 = phi i64 [ %30, %28 ], [ 0, %11 ]
%17 = load i32, i32* %2
%18 = icmp slt i32 %17, 0
br i1 %18, label %28, label %19
19: ; preds = %15, %19
%20 = phi i64 [ %24, %19 ], [ 0, %15 ]
%21 = getelementptr inbounds [25 x [25 x double]], [25 x [25 x double]]* %0, i64 %20, i64 %16, i64 %12
%22 = load double, double* %21
%23 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), double %22)
%24 = add nuw nsw i64 %20, 1
%25 = load i32, i32* %2
%26 = sext i32 %25 to i64
%27 = icmp slt i64 %20, %26
br i1 %27, label %19, label %28
28: ; preds = %19, %15
%29 = call i32 @putchar(i32 10)
%30 = add nuw nsw i64 %16, 1
%31 = load i32, i32* %3
%32 = sext i32 %31 to i64
%33 = icmp slt i64 %16, %32
br i1 %33, label %15, label %34
34: ; preds = %28, %11
%35 = call i32 @putchar(i32 10)
%36 = add nuw nsw i64 %12, 1
%37 = load i32, i32* %4
%38 = sext i32 %37 to i64
%39 = icmp slt i64 %12, %38
br i1 %39, label %11, label %40
40: ; preds = %34, %1
ret i32 undef
}