source
stringlengths
3
46
c
stringlengths
31
48.4k
risc_o0
stringlengths
130
91k
risc_o1
stringlengths
130
86.5k
risc_o2
stringlengths
130
94.6k
risc_o3
stringlengths
130
110k
arm_o0
stringlengths
132
111k
arm_o1
stringlengths
132
113k
arm_o2
stringlengths
132
135k
arm_o3
stringlengths
132
162k
1050.c
/* URI Online Judge | 1050 DDD Adapted by Neilor Tonin, URI Brazil https://www.urionlinejudge.com.br/judge/en/problems/view/1050 Timelimit: 1 Read an integer number that is the code number for phone dialing. Then, print the destination according to the following table: 61 Brasilia 71 Salvador 11 Sao Paulo 21 Rio...
.file "1050.c" .option pic .text .section .rodata .align 3 .LC0: .string "%d" .align 3 .LC1: .string "Sao Paulo" .align 3 .LC2: .string "Campinas" .align 3 .LC3: .string "Rio de Janeiro" .align 3 .LC4: .string "Vitoria" .align 3 .LC5: .string "Belo Horizonte" .align 3 .LC6: .string "Juiz de Fora" .al...
.file "1050.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "%d" .align 3 .LC1: .string "Sao Paulo" .align 3 .LC2: .string "Campinas" .align 3 .LC3: .string "Rio de Janeiro" .align 3 .LC4: .string "Vitoria" .align 3 .LC5: .string "Belo Horizonte" .align 3 .LC6: .s...
.file "1050.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "%d" .align 3 .LC1: .string "Sao Paulo" .align 3 .LC2: .string "Campinas" .align 3 .LC3: .string "Rio de Janeiro" .align 3 .LC4: .string "Vitoria" .align 3 .LC5: .string "Belo Horizonte" .align 3 .LC6: .s...
.file "1050.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "%d" .align 3 .LC1: .string "Sao Paulo" .align 3 .LC2: .string "Campinas" .align 3 .LC3: .string "Rio de Janeiro" .align 3 .LC4: .string "Vitoria" .align 3 .LC5: .string "Belo Horizonte" .align 3 .LC6: .s...
.arch armv8-a .file "1050.c" .text .section .rodata .align 3 .LC0: .string "%d" .align 3 .LC1: .string "Sao Paulo" .align 3 .LC2: .string "Campinas" .align 3 .LC3: .string "Rio de Janeiro" .align 3 .LC4: .string "Vitoria" .align 3 .LC5: .string "Belo Horizonte" .align 3 .LC6: .string "Juiz de Fora" ....
.arch armv8-a .file "1050.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "%d" .align 3 .LC1: .string "Sao Paulo" .align 3 .LC2: .string "Campinas" .align 3 .LC3: .string "Rio de Janeiro" .align 3 .LC4: .string "Vitoria" .align 3 .LC5: .string "Belo Horizonte" .align 3 .LC6: ...
.arch armv8-a .file "1050.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "%d" .align 3 .LC1: .string "Sao Paulo" .align 3 .LC2: .string "Campinas" .align 3 .LC3: .string "Rio de Janeiro" .align 3 .LC4: .string "Vitoria" .align 3 .LC5: .string "Belo Horizonte" .align 3 .LC6: ...
.arch armv8-a .file "1050.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "%d" .align 3 .LC1: .string "Sao Paulo" .align 3 .LC2: .string "Campinas" .align 3 .LC3: .string "Rio de Janeiro" .align 3 .LC4: .string "Vitoria" .align 3 .LC5: .string "Belo Horizonte" .align 3 .LC6: ...
pointers.c
void func() { char* string = "Hello"; }
.file "pointers.c" .option pic .text .section .rodata .align 3 .LC0: .string "Hello" .text .align 1 .globl func .type func, @function func: addi sp,sp,-32 sd s0,24(sp) addi s0,sp,32 lla a5,.LC0 sd a5,-24(s0) nop ld s0,24(sp) addi sp,sp,32 jr ra .size func, .-func .ident "GCC: (Ubuntu 11.3.0-1ubuntu...
.file "pointers.c" .option pic .text .align 1 .globl func .type func, @function func: ret .size func, .-func .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.file "pointers.c" .option pic .text .align 1 .globl func .type func, @function func: ret .size func, .-func .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.file "pointers.c" .option pic .text .align 1 .globl func .type func, @function func: ret .size func, .-func .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.arch armv8-a .file "pointers.c" .text .section .rodata .align 3 .LC0: .string "Hello" .text .align 2 .global func .type func, %function func: .LFB0: .cfi_startproc sub sp, sp, #16 .cfi_def_cfa_offset 16 adrp x0, .LC0 add x0, x0, :lo12:.LC0 str x0, [sp, 8] nop add sp, sp, 16 .cfi_def_cfa_offset 0 re...
.arch armv8-a .file "pointers.c" .text .align 2 .global func .type func, %function func: .LFB0: .cfi_startproc ret .cfi_endproc .LFE0: .size func, .-func .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.arch armv8-a .file "pointers.c" .text .align 2 .p2align 4,,11 .global func .type func, %function func: .LFB0: .cfi_startproc ret .cfi_endproc .LFE0: .size func, .-func .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.arch armv8-a .file "pointers.c" .text .align 2 .p2align 4,,11 .global func .type func, %function func: .LFB0: .cfi_startproc ret .cfi_endproc .LFE0: .size func, .-func .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
Wstring-literal-comparison-3.c
/* PR c/7776 */ /* { dg-do compile } */ /* { dg-options "" } */ int test1(char *ptr) { return ptr == "foo"; } int test2() { return "foo" != (const char*)0; } int test3() { return "foo" == (const char*)0; } int test4() { return (const char*)0 != "foo"; } int test5() { return (const char*)0 == "foo"; }
.file "Wstring-literal-comparison-3.c" .option pic .text .section .rodata .align 3 .LC0: .string "foo" .text .align 1 .globl test1 .type test1, @function test1: addi sp,sp,-32 sd s0,24(sp) addi s0,sp,32 sd a0,-24(s0) ld a4,-24(s0) lla a5,.LC0 sub a5,a4,a5 seqz a5,a5 andi a5,a5,0xff sext.w a5,a5 mv ...
.file "Wstring-literal-comparison-3.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "foo" .text .align 1 .globl test1 .type test1, @function test1: lla a5,.LC0 sub a0,a0,a5 seqz a0,a0 ret .size test1, .-test1 .align 1 .globl test2 .type test2, @function test2: li...
.file "Wstring-literal-comparison-3.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "foo" .text .align 1 .globl test1 .type test1, @function test1: lla a5,.LC0 sub a0,a0,a5 seqz a0,a0 ret .size test1, .-test1 .align 1 .globl test2 .type test2, @function test2: li...
.file "Wstring-literal-comparison-3.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "foo" .text .align 1 .globl test1 .type test1, @function test1: lla a5,.LC0 sub a0,a0,a5 seqz a0,a0 ret .size test1, .-test1 .align 1 .globl test2 .type test2, @function test2: li...
.arch armv8-a .file "Wstring-literal-comparison-3.c" .text .section .rodata .align 3 .LC0: .string "foo" .text .align 2 .global test1 .type test1, %function test1: .LFB0: .cfi_startproc sub sp, sp, #16 .cfi_def_cfa_offset 16 str x0, [sp, 8] ldr x1, [sp, 8] adrp x0, .LC0 add x0, x0, :lo12:.LC0 cmp x1, ...
.arch armv8-a .file "Wstring-literal-comparison-3.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "foo" .text .align 2 .global test1 .type test1, %function test1: .LFB0: .cfi_startproc adrp x1, .LC0 add x1, x1, :lo12:.LC0 cmp x1, x0 cset w0, eq ret .cfi_endproc .LFE0: .size t...
.arch armv8-a .file "Wstring-literal-comparison-3.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "foo" .text .align 2 .p2align 4,,11 .global test1 .type test1, %function test1: .LFB0: .cfi_startproc adrp x1, .LC0 add x1, x1, :lo12:.LC0 cmp x1, x0 cset w0, eq ret .cfi_endproc...
.arch armv8-a .file "Wstring-literal-comparison-3.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "foo" .text .align 2 .p2align 4,,11 .global test1 .type test1, %function test1: .LFB0: .cfi_startproc adrp x1, .LC0 add x1, x1, :lo12:.LC0 cmp x1, x0 cset w0, eq ret .cfi_endproc...
hex2bin.c
/* * hex2bin - converts data in hexadecimal form to binary form * * Copyright (C) 2013 Jonathan Buhacoff <jonathan@buhacoff.net> * * BSD license. * * Input must contain only hex characters. Any other characters will result in an error * printed to stderr and exit code 1. On success exit code is 0. * * Would ...
.file "hex2bin.c" .option pic .text .align 1 .globl hex2int .type hex2int, @function hex2int: addi sp,sp,-32 sd s0,24(sp) addi s0,sp,32 mv a5,a0 sb a5,-17(s0) lbu a5,-17(s0) andi a4,a5,0xff li a5,47 bleu a4,a5,.L2 lbu a5,-17(s0) andi a4,a5,0xff li a5,57 bgtu a4,a5,.L2 lbu a5,-17(s0) sext.w a5,a5 a...
.file "hex2bin.c" .option pic .text .align 1 .globl hex2int .type hex2int, @function hex2int: addiw a5,a0,-48 andi a5,a5,0xff li a4,9 bleu a5,a4,.L6 addiw a5,a0,-65 andi a5,a5,0xff li a4,5 bleu a5,a4,.L7 addiw a5,a0,-97 andi a5,a5,0xff li a4,5 bgtu a5,a4,.L5 addiw a0,a0,-87 ret .L6: addiw a0,a0,-48...
.file "hex2bin.c" .option pic .text .align 1 .globl hex2int .type hex2int, @function hex2int: addiw a5,a0,-48 andi a3,a5,0xff li a4,9 bleu a3,a4,.L7 addiw a5,a0,-65 andi a5,a5,0xff li a4,5 bleu a5,a4,.L8 addiw a5,a0,-97 andi a5,a5,0xff bgtu a5,a4,.L5 addiw a0,a0,-87 ret .L8: addiw a0,a0,-55 ret .L7...
.file "hex2bin.c" .option pic .text .align 1 .globl hex2int .type hex2int, @function hex2int: addiw a5,a0,-48 andi a3,a5,0xff li a4,9 bleu a3,a4,.L7 addiw a5,a0,-65 andi a5,a5,0xff li a4,5 bleu a5,a4,.L8 addiw a5,a0,-97 andi a5,a5,0xff bgtu a5,a4,.L5 addiw a0,a0,-87 ret .L8: addiw a0,a0,-55 ret .L7...
.arch armv8-a .file "hex2bin.c" .text .align 2 .global hex2int .type hex2int, %function hex2int: .LFB6: .cfi_startproc sub sp, sp, #16 .cfi_def_cfa_offset 16 strb w0, [sp, 15] ldrb w0, [sp, 15] cmp w0, 47 bls .L2 ldrb w0, [sp, 15] cmp w0, 57 bhi .L2 ldrb w0, [sp, 15] sub w0, w0, #48 b .L3 .L2: ldrb ...
.arch armv8-a .file "hex2bin.c" .text .align 2 .global hex2int .type hex2int, %function hex2int: .LFB39: .cfi_startproc and w0, w0, 255 sub w1, w0, #48 and w1, w1, 255 cmp w1, 9 bls .L6 sub w1, w0, #65 and w1, w1, 255 cmp w1, 5 bls .L7 sub w1, w0, #97 and w1, w1, 255 cmp w1, 5 bhi .L5 sub w0, w0, #...
.arch armv8-a .file "hex2bin.c" .text .align 2 .p2align 4,,11 .global hex2int .type hex2int, %function hex2int: .LFB39: .cfi_startproc and w1, w0, 255 sub w0, w1, #48 and w2, w0, 255 cmp w2, 9 bls .L1 sub w0, w1, #65 and w0, w0, 255 cmp w0, 5 bls .L7 sub w0, w1, #97 and w0, w0, 255 cmp w0, 5 bhi .L...
.arch armv8-a .file "hex2bin.c" .text .align 2 .p2align 4,,11 .global hex2int .type hex2int, %function hex2int: .LFB39: .cfi_startproc and w1, w0, 255 sub w0, w1, #48 and w2, w0, 255 cmp w2, 9 bls .L1 sub w0, w1, #65 and w0, w0, 255 cmp w0, 5 bls .L7 sub w0, w1, #97 and w0, w0, 255 cmp w0, 5 bhi .L...
ds2490.c
const char dtlib[] = "DS2490";
.file "ds2490.c" .option pic .text .globl dtlib .section .rodata .align 3 .type dtlib, @object .size dtlib, 7 dtlib: .string "DS2490" .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.file "ds2490.c" .option pic .text .globl dtlib .section .rodata .align 3 .type dtlib, @object .size dtlib, 7 dtlib: .string "DS2490" .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.file "ds2490.c" .option pic .text .globl dtlib .section .rodata .align 3 .type dtlib, @object .size dtlib, 7 dtlib: .string "DS2490" .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.file "ds2490.c" .option pic .text .globl dtlib .section .rodata .align 3 .type dtlib, @object .size dtlib, 7 dtlib: .string "DS2490" .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.arch armv8-a .file "ds2490.c" .text .global dtlib .section .rodata .align 3 .type dtlib, %object .size dtlib, 7 dtlib: .string "DS2490" .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.arch armv8-a .file "ds2490.c" .text .global dtlib .section .rodata .align 3 .type dtlib, %object .size dtlib, 7 dtlib: .string "DS2490" .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.arch armv8-a .file "ds2490.c" .text .global dtlib .section .rodata .align 3 .type dtlib, %object .size dtlib, 7 dtlib: .string "DS2490" .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.arch armv8-a .file "ds2490.c" .text .global dtlib .section .rodata .align 3 .type dtlib, %object .size dtlib, 7 dtlib: .string "DS2490" .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
linearsearch.c
#include<stdio.h> struct Array { int A[10]; int size; int length; }; void Display(struct Array arr) { int i; printf("\nElements are\n"); for(i=0;i<arr.length;i++) printf("%d ",arr.A[i]); } void Append(struct Array *arr,int x) { if(arr->length<arr->size) arr->A[arr->length++]=...
.file "linearsearch.c" .option pic .text .section .rodata .align 3 .LC0: .string "\nElements are" .align 3 .LC1: .string "%d " .text .align 1 .globl Display .type Display, @function Display: addi sp,sp,-48 sd ra,40(sp) sd s0,32(sp) sd s1,24(sp) addi s0,sp,48 mv s1,a0 lla a0,.LC0 call puts@plt sw ze...
.file "linearsearch.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "\nElements are" .align 3 .LC1: .string "%d " .text .align 1 .globl Display .type Display, @function Display: addi sp,sp,-32 sd ra,24(sp) sd s0,16(sp) sd s1,8(sp) sd s2,0(sp) mv s2,a0 lw s1,44(a0...
.file "linearsearch.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "\nElements are" .align 3 .LC1: .string "%d " .text .align 1 .globl Display .type Display, @function Display: addi sp,sp,-32 sd s1,8(sp) lw s1,44(a0) sd s0,16(sp) mv s0,a0 lla a0,.LC0 sd ra,24(sp...
.file "linearsearch.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "\nElements are" .align 3 .LC1: .string "%d " .text .align 1 .globl Display .type Display, @function Display: addi sp,sp,-32 sd s1,8(sp) lw s1,44(a0) sd s0,16(sp) mv s0,a0 lla a0,.LC0 sd ra,24(sp...
.arch armv8-a .file "linearsearch.c" .text .section .rodata .align 3 .LC0: .string "\nElements are" .align 3 .LC1: .string "%d " .text .align 2 .global Display .type Display, %function Display: .LFB0: .cfi_startproc stp x29, x30, [sp, -48]! .cfi_def_cfa_offset 48 .cfi_offset 29, -48 .cfi_offset 30, -40...
.arch armv8-a .file "linearsearch.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "\nElements are" .align 3 .LC1: .string "%d " .text .align 2 .global Display .type Display, %function Display: .LFB23: .cfi_startproc stp x29, x30, [sp, -64]! .cfi_def_cfa_offset 64 .cfi_offset 29...
.arch armv8-a .file "linearsearch.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "\nElements are" .align 3 .LC1: .string "%d " .text .align 2 .p2align 4,,11 .global Display .type Display, %function Display: .LFB23: .cfi_startproc stp x29, x30, [sp, -48]! .cfi_def_cfa_offset 48...
.arch armv8-a .file "linearsearch.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "\nElements are" .align 3 .LC1: .string "%d " .text .align 2 .p2align 4,,11 .global Display .type Display, %function Display: .LFB23: .cfi_startproc stp x29, x30, [sp, -48]! .cfi_def_cfa_offset 48...
main.c
/*------------------------------------------------------------ PROGRAMACIÓN AVANZADA HW01P04 Andrés César Magaña Martínez cesar@cimat.mx --------------------------------------------------------------*/ float SumFloats (int n){ int i; float sumf = 0.0; for ( i=1; i<n+1; i++ ) sumf+=(1/(float)n); return sumf; } ...
.file "main.c" .option pic .text .align 1 .globl SumFloats .type SumFloats, @function SumFloats: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 mv a5,a0 sw a5,-36(s0) sw zero,-20(s0) li a5,1 sw a5,-24(s0) j .L2 .L3: lw a5,-36(s0) fcvt.s.w fa5,a5 lla a5,.LC0 flw fa4,0(a5) fdiv.s fa5,fa4,fa5 flw fa4,-20(s...
.file "main.c" .option pic .text .align 1 .globl SumFloats .type SumFloats, @function SumFloats: ble a0,zero,.L4 fcvt.s.w fa4,a0 flw fa5,.LC0,a5 fdiv.s fa5,fa5,fa4 addiw a0,a0,1 fmv.w.x fa0,zero li a5,1 .L3: fadd.s fa0,fa0,fa5 addiw a5,a5,1 bne a5,a0,.L3 ret .L4: fmv.w.x fa0,zero ret .size SumFloats...
.file "main.c" .option pic .text .align 1 .globl SumFloats .type SumFloats, @function SumFloats: ble a0,zero,.L4 fcvt.s.w fa4,a0 flw fa5,.LC0,a5 fmv.w.x fa0,zero fdiv.s fa5,fa5,fa4 addiw a0,a0,1 li a5,1 .L3: addiw a5,a5,1 fadd.s fa0,fa0,fa5 bne a5,a0,.L3 ret .L4: fmv.w.x fa0,zero ret .size SumFloats...
.file "main.c" .option pic .text .align 1 .globl SumFloats .type SumFloats, @function SumFloats: ble a0,zero,.L4 fcvt.s.w fa4,a0 flw fa5,.LC0,a5 fmv.w.x fa0,zero fdiv.s fa5,fa5,fa4 addiw a0,a0,1 li a5,1 .L3: addiw a5,a5,1 fadd.s fa0,fa0,fa5 bne a5,a0,.L3 ret .L4: fmv.w.x fa0,zero ret .size SumFloats...
.arch armv8-a .file "main.c" .text .align 2 .global SumFloats .type SumFloats, %function SumFloats: .LFB0: .cfi_startproc sub sp, sp, #32 .cfi_def_cfa_offset 32 str w0, [sp, 12] str wzr, [sp, 28] mov w0, 1 str w0, [sp, 24] b .L2 .L3: ldr s0, [sp, 12] scvtf s0, s0 fmov s1, 1.0e+0 fdiv s0, s1, s0 ldr s...
.arch armv8-a .file "main.c" .text .align 2 .global SumFloats .type SumFloats, %function SumFloats: .LFB0: .cfi_startproc cmp w0, 0 ble .L4 scvtf s0, w0 fmov s1, 1.0e+0 fdiv s1, s1, s0 add w1, w0, 1 movi v0.2s, #0 mov w0, 1 .L3: fadd s0, s0, s1 add w0, w0, 1 cmp w0, w1 bne .L3 .L1: ret .L4: movi v0...
.arch armv8-a .file "main.c" .text .align 2 .p2align 4,,11 .global SumFloats .type SumFloats, %function SumFloats: .LFB0: .cfi_startproc cmp w0, 0 ble .L4 scvtf s2, w0 fmov s1, 1.0e+0 movi v0.2s, #0 add w1, w0, 1 mov w0, 1 fdiv s1, s1, s2 .p2align 3,,7 .L3: add w0, w0, 1 fadd s0, s0, s1 cmp w0, w1 ...
.arch armv8-a .file "main.c" .text .align 2 .p2align 4,,11 .global SumFloats .type SumFloats, %function SumFloats: .LFB0: .cfi_startproc cmp w0, 0 ble .L4 scvtf s2, w0 fmov s1, 1.0e+0 movi v0.2s, #0 add w1, w0, 1 mov w0, 1 fdiv s1, s1, s2 .p2align 3,,7 .L3: add w0, w0, 1 fadd s0, s0, s1 cmp w0, w1 ...
oppgave1.c
#include <stdio.h> struct deltager { char navn[30]; int poeng; }; int main(void){ struct deltager jim, tom; printf("Navn 1: "); scanf("%s", jim.navn); printf("Poeng:"); scanf("%d", &jim.poeng); printf("Navn 2: "); scanf("%s", tom.navn); printf("Poeng:"); scanf("%d", &tom.poeng); if(tom.poeng<jim.poeng...
.file "oppgave1.c" .option pic .text .section .rodata .align 3 .LC0: .string "Navn 1: " .align 3 .LC1: .string "%s" .align 3 .LC2: .string "Poeng:" .align 3 .LC3: .string "%d" .align 3 .LC4: .string "Navn 2: " .align 3 .LC5: .string "%s, vinner\n" .text .align 1 .globl main .type main, @function mai...
.file "oppgave1.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "Navn 1: " .align 3 .LC1: .string "%s" .align 3 .LC2: .string "Poeng:" .align 3 .LC3: .string "%d" .align 3 .LC4: .string "Navn 2: " .align 3 .LC5: .string "%s, vinner\n" .text .align 1 .globl main ...
.file "oppgave1.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "Navn 1: " .align 3 .LC1: .string "%s" .align 3 .LC2: .string "Poeng:" .align 3 .LC3: .string "%d" .align 3 .LC4: .string "Navn 2: " .align 3 .LC5: .string "%s, vinner\n" .section .text.startup,"ax",@p...
.file "oppgave1.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "Navn 1: " .align 3 .LC1: .string "%s" .align 3 .LC2: .string "Poeng:" .align 3 .LC3: .string "%d" .align 3 .LC4: .string "Navn 2: " .align 3 .LC5: .string "%s, vinner\n" .section .text.startup,"ax",@p...
.arch armv8-a .file "oppgave1.c" .text .section .rodata .align 3 .LC0: .string "Navn 1: " .align 3 .LC1: .string "%s" .align 3 .LC2: .string "Poeng:" .align 3 .LC3: .string "%d" .align 3 .LC4: .string "Navn 2: " .align 3 .LC5: .string "%s, vinner\n" .text .align 2 .global main .type main, %function ...
.arch armv8-a .file "oppgave1.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "Navn 1: " .align 3 .LC1: .string "%s" .align 3 .LC2: .string "Poeng:" .align 3 .LC3: .string "%d" .align 3 .LC4: .string "Navn 2: " .align 3 .LC5: .string "%s, vinner\n" .text .align 2 .global mai...
.arch armv8-a .file "oppgave1.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "Navn 1: " .align 3 .LC1: .string "%s" .align 3 .LC2: .string "Poeng:" .align 3 .LC3: .string "%d" .align 3 .LC4: .string "Navn 2: " .align 3 .LC5: .string "%s, vinner\n" .section .text.startup,"ax",...
.arch armv8-a .file "oppgave1.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "Navn 1: " .align 3 .LC1: .string "%s" .align 3 .LC2: .string "Poeng:" .align 3 .LC3: .string "%d" .align 3 .LC4: .string "Navn 2: " .align 3 .LC5: .string "%s, vinner\n" .section .text.startup,"ax",...
6.c
#include<stdio.h> #include<stdlib.h> #define size 5 int cq[size],f=-1,r=-1,elm; void display(); int full(); int empty(); void insert(int); int delete(); void main() { int ch; while(1){ printf("\n############### C-Q MENU #############\n"); printf("1.Insert\t2.Delete\t3.Display\t4.Exit\n"); printf("Enter Your Choic...
.file "6.c" .option pic .text .globl cq .bss .align 3 .type cq, @object .size cq, 20 cq: .zero 20 .globl f .data .align 2 .type f, @object .size f, 4 f: .word -1 .globl r .align 2 .type r, @object .size r, 4 r: .word -1 .globl elm .bss .align 2 .type elm, @object .size elm, 4 elm: .zero 4 .se...
.file "6.c" .option pic .text .align 1 .globl full .type full, @function full: lla a4,.LANCHOR0 lw a5,0(a4) lw a4,4(a4) addiw a3,a5,1 li a0,1 beq a3,a4,.L2 li a0,0 bne a4,zero,.L2 addi a5,a5,-4 seqz a0,a5 .L2: ret .size full, .-full .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "...
.file "6.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "CQ Overflow!..." .text .align 1 .globl insert .type insert, @function insert: lla a4,.LANCHOR0 lw a2,0(a4) lw a3,4(a4) addiw a1,a2,1 mv a5,a1 beq a1,a3,.L2 bne a3,zero,.L3 li a3,4 beq a2,a3,.L2 .L4: li a3...
.file "6.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "CQ Overflow!..." .text .align 1 .globl insert .type insert, @function insert: lla a4,.LANCHOR0 lw a2,0(a4) lw a3,4(a4) addiw a1,a2,1 mv a5,a1 beq a1,a3,.L2 beq a3,zero,.L6 li a2,-1 bne a3,a2,.L4 sw zero,....
.arch armv8-a .file "6.c" .text .global cq .bss .align 3 .type cq, %object .size cq, 20 cq: .zero 20 .global f .data .align 2 .type f, %object .size f, 4 f: .word -1 .global r .align 2 .type r, %object .size r, 4 r: .word -1 .global elm .bss .align 2 .type elm, %object .size elm, 4 elm: .zero ...
.arch armv8-a .file "6.c" .text .align 2 .global full .type full, %function full: .LFB42: .cfi_startproc adrp x0, .LANCHOR0 add x2, x0, :lo12:.LANCHOR0 ldr w1, [x0, #:lo12:.LANCHOR0] ldr w2, [x2, 4] add w3, w1, 1 mov w0, 1 cmp w3, w2 beq .L1 cmp w2, 0 ccmp w1, 4, 0, eq cset w0, eq .L1: ret .cfi_endp...
.arch armv8-a .file "6.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "CQ Overflow!..." .text .align 2 .p2align 4,,11 .global insert .type insert, %function insert: .LFB40: .cfi_startproc adrp x3, .LANCHOR0 add x5, x3, :lo12:.LANCHOR0 ldr w4, [x3, #:lo12:.LANCHOR0] ldr w1, [x5...
.arch armv8-a .file "6.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "CQ Overflow!..." .text .align 2 .p2align 4,,11 .global insert .type insert, %function insert: .LFB40: .cfi_startproc adrp x3, .LANCHOR0 add x5, x3, :lo12:.LANCHOR0 ldr w4, [x3, #:lo12:.LANCHOR0] ldr w1, [x5...
compile000d.c
int main(int argc, char **argv) { if (argc || argc - 1) return 2; return 1; }
.file "compile000d.c" .option pic .text .align 1 .globl main .type main, @function main: addi sp,sp,-32 sd s0,24(sp) addi s0,sp,32 mv a5,a0 sd a1,-32(s0) sw a5,-20(s0) lw a5,-20(s0) sext.w a5,a5 bne a5,zero,.L2 lw a5,-20(s0) sext.w a4,a5 li a5,1 beq a4,a5,.L3 .L2: li a5,2 j .L4 .L3: li a5,1 .L4: ...
.file "compile000d.c" .option pic .text .align 1 .globl main .type main, @function main: li a0,2 ret .size main, .-main .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.file "compile000d.c" .option pic .text .section .text.startup,"ax",@progbits .align 1 .globl main .type main, @function main: li a0,2 ret .size main, .-main .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.file "compile000d.c" .option pic .text .section .text.startup,"ax",@progbits .align 1 .globl main .type main, @function main: li a0,2 ret .size main, .-main .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.arch armv8-a .file "compile000d.c" .text .align 2 .global main .type main, %function main: .LFB0: .cfi_startproc sub sp, sp, #16 .cfi_def_cfa_offset 16 str w0, [sp, 12] str x1, [sp] ldr w0, [sp, 12] cmp w0, 0 bne .L2 ldr w0, [sp, 12] cmp w0, 1 beq .L3 .L2: mov w0, 2 b .L4 .L3: mov w0, 1 .L4: add s...
.arch armv8-a .file "compile000d.c" .text .align 2 .global main .type main, %function main: .LFB0: .cfi_startproc mov w0, 2 ret .cfi_endproc .LFE0: .size main, .-main .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.arch armv8-a .file "compile000d.c" .text .section .text.startup,"ax",@progbits .align 2 .p2align 4,,11 .global main .type main, %function main: .LFB0: .cfi_startproc mov w0, 2 ret .cfi_endproc .LFE0: .size main, .-main .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@prog...
.arch armv8-a .file "compile000d.c" .text .section .text.startup,"ax",@progbits .align 2 .p2align 4,,11 .global main .type main, %function main: .LFB0: .cfi_startproc mov w0, 2 ret .cfi_endproc .LFE0: .size main, .-main .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@prog...
q1_server.c
#include<string.h> #include<unistd.h> #include<sys/socket.h> #include<sys/types.h> #include<netinet/in.h> #include<stdlib.h> #include<stdio.h> #define MAX_LEN 100 void replaceAll(char *str, const char *oldWord, const char *newWord) { char *pos, temp[1000]; int index = 0; int owlen; owlen = strlen(oldWord); ...
.file "q1_server.c" .option pic .text .align 1 .globl replaceAll .type replaceAll, @function replaceAll: addi sp,sp,-1072 sd ra,1064(sp) sd s0,1056(sp) addi s0,sp,1072 sd a0,-1048(s0) sd a1,-1056(s0) sd a2,-1064(s0) la a5,__stack_chk_guard ld a4, 0(a5) sd a4, -24(s0) li a4, 0 sw zero,-1040(s0) ld a0,...
.file "q1_server.c" .option pic .text .align 1 .globl replaceAll .type replaceAll, @function replaceAll: addi sp,sp,-1072 sd ra,1064(sp) sd s0,1056(sp) sd s1,1048(sp) sd s2,1040(sp) sd s3,1032(sp) sd s4,1024(sp) sd s5,1016(sp) mv s1,a0 mv s3,a1 mv s5,a2 la a5,__stack_chk_guard ld a4, 0(a5) sd a4, 10...
.file "q1_server.c" .option pic .text .align 1 .globl replaceAll .type replaceAll, @function replaceAll: addi sp,sp,-1072 sd s6,1008(sp) la s6,__stack_chk_guard sd s1,1048(sp) ld a5, 0(s6) sd a5, 1000(sp) li a5, 0 mv s1,a0 mv a0,a1 sd s2,1040(sp) sd s3,1032(sp) sd s4,1024(sp) sd s5,1016(sp) sd ra,10...
.file "q1_server.c" .option pic .text .align 1 .globl replaceAll .type replaceAll, @function replaceAll: addi sp,sp,-1072 sd s6,1008(sp) la s6,__stack_chk_guard sd s1,1048(sp) ld a5, 0(s6) sd a5, 1000(sp) li a5, 0 mv s1,a0 mv a0,a1 sd s2,1040(sp) sd s3,1032(sp) sd s4,1024(sp) sd s5,1016(sp) sd ra,10...
.arch armv8-a .file "q1_server.c" .text .align 2 .global replaceAll .type replaceAll, %function replaceAll: .LFB6: .cfi_startproc sub sp, sp, #1072 .cfi_def_cfa_offset 1072 stp x29, x30, [sp] .cfi_offset 29, -1072 .cfi_offset 30, -1064 mov x29, sp str x0, [sp, 40] str x1, [sp, 32] str x2, [sp, 24] adrp...
.arch armv8-a .file "q1_server.c" .text .align 2 .global replaceAll .type replaceAll, %function replaceAll: .LFB66: .cfi_startproc sub sp, sp, #1088 .cfi_def_cfa_offset 1088 stp x29, x30, [sp] .cfi_offset 29, -1088 .cfi_offset 30, -1080 mov x29, sp stp x19, x20, [sp, 16] stp x21, x22, [sp, 32] stp x23, ...
.arch armv8-a .file "q1_server.c" .text .align 2 .p2align 4,,11 .global replaceAll .type replaceAll, %function replaceAll: .LFB66: .cfi_startproc sub sp, sp, #1072 .cfi_def_cfa_offset 1072 adrp x3, :got:__stack_chk_guard stp x29, x30, [sp] .cfi_offset 29, -1072 .cfi_offset 30, -1064 mov x29, sp ldr x3, ...
.arch armv8-a .file "q1_server.c" .text .align 2 .p2align 4,,11 .global replaceAll .type replaceAll, %function replaceAll: .LFB66: .cfi_startproc sub sp, sp, #1072 .cfi_def_cfa_offset 1072 adrp x3, :got:__stack_chk_guard stp x29, x30, [sp] .cfi_offset 29, -1072 .cfi_offset 30, -1064 mov x29, sp ldr x3, ...
entertainment3.c
#include<stdio.h> #include<stdlib.h> struct opponents { long long int skill,entertainment; }; struct opponents p2[100005]; typedef struct opponents opp; int bound_lower(long long int p,long long int pri) { int small,big; long long int ret=p; for(small=0,big=p-1;small<big;) { int m=(small+big)>>1; if(p2...
.file "entertainment3.c" .option pic .text .globl p2 .bss .align 3 .type p2, @object .size p2, 1600080 p2: .zero 1600080 .text .align 1 .globl bound_lower .type bound_lower, @function bound_lower: addi sp,sp,-64 sd s0,56(sp) addi s0,sp,64 sd a0,-56(s0) sd a1,-64(s0) ld a5,-56(s0) sd a5,-24(s0) sw z...
.file "entertainment3.c" .option pic .text .align 1 .globl fnccompare .type fnccompare, @function fnccompare: ld a0,0(a0) ld a5,0(a1) blt a0,a5,.L3 sgt a0,a0,a5 ret .L3: li a0,-1 ret .size fnccompare, .-fnccompare .align 1 .globl bound_lower .type bound_lower, @function bound_lower: addiw a3,a0,-1 bl...
.file "entertainment3.c" .option pic .text .align 1 .globl fnccompare .type fnccompare, @function fnccompare: ld a0,0(a0) ld a5,0(a1) blt a0,a5,.L3 sgt a0,a0,a5 ret .L3: li a0,-1 ret .size fnccompare, .-fnccompare .align 1 .globl bound_lower .type bound_lower, @function bound_lower: mv a7,a0 addiw a0...
.file "entertainment3.c" .option pic .text .align 1 .globl fnccompare .type fnccompare, @function fnccompare: ld a0,0(a0) ld a5,0(a1) blt a0,a5,.L3 sgt a0,a0,a5 ret .L3: li a0,-1 ret .size fnccompare, .-fnccompare .align 1 .globl bound_lower .type bound_lower, @function bound_lower: mv a7,a0 addiw a0...
.arch armv8-a .file "entertainment3.c" .text .global p2 .bss .align 3 .type p2, %object .size p2, 1600080 p2: .zero 1600080 .text .align 2 .global bound_lower .type bound_lower, %function bound_lower: .LFB6: .cfi_startproc sub sp, sp, #48 .cfi_def_cfa_offset 48 str x0, [sp, 8] str x1, [sp] ldr x0, [s...
.arch armv8-a .file "entertainment3.c" .text .align 2 .global fnccompare .type fnccompare, %function fnccompare: .LFB42: .cfi_startproc ldr x2, [x0] ldr x0, [x1] cmp x2, x0 blt .L3 cset w0, gt .L1: ret .L3: mov w0, -1 b .L1 .cfi_endproc .LFE42: .size fnccompare, .-fnccompare .align 2 .global bound_lo...
.arch armv8-a .file "entertainment3.c" .text .align 2 .p2align 4,,11 .global fnccompare .type fnccompare, %function fnccompare: .LFB42: .cfi_startproc ldr x2, [x0] ldr x0, [x1] cmp x2, x0 cset w0, gt csinv w0, w0, wzr, ge ret .cfi_endproc .LFE42: .size fnccompare, .-fnccompare .align 2 .p2align 4,,11 ...
.arch armv8-a .file "entertainment3.c" .text .align 2 .p2align 4,,11 .global fnccompare .type fnccompare, %function fnccompare: .LFB42: .cfi_startproc ldr x2, [x0] ldr x0, [x1] cmp x2, x0 cset w0, gt csinv w0, w0, wzr, ge ret .cfi_endproc .LFE42: .size fnccompare, .-fnccompare .align 2 .p2align 4,,11 ...
osoba.c
#include <stdio.h> #include <stdlib.h> #include <sys/ipc.h> #include <sys/types.h> #include <sys/sem.h> #include <sys/shm.h> #include <errno.h> #include <unistd.h> union semun { int val; struct semid_ds *buf; unsigned short *array; }; #define H 1 int main() { key_t kljuc = ftok("./osoba.c", 'a'); int...
.file "osoba.c" .option pic .text .section .rodata .align 3 .LC0: .string "./osoba.c" .align 3 .LC1: .string "Ubacio sam novcic, pary (%d)\n" .text .align 1 .globl main .type main, @function main: addi sp,sp,-80 sd ra,72(sp) sd s0,64(sp) addi s0,sp,80 la a5,__stack_chk_guard ld a4, 0(a5) sd a4, -24(s...
.file "osoba.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "./osoba.c" .align 3 .LC1: .string "Ubacio sam novcic, pary (%d)\n" .text .align 1 .globl main .type main, @function main: addi sp,sp,-80 sd ra,72(sp) sd s0,64(sp) sd s1,56(sp) sd s2,48(sp) la a5,__stack...
.file "osoba.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "./osoba.c" .align 3 .LC1: .string "Ubacio sam novcic, pary (%d)\n" .section .text.startup,"ax",@progbits .align 1 .globl main .type main, @function main: addi sp,sp,-96 sd s3,56(sp) la s3,__stack_chk_guard...
.file "osoba.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "./osoba.c" .align 3 .LC1: .string "Ubacio sam novcic, pary (%d)\n" .section .text.startup,"ax",@progbits .align 1 .globl main .type main, @function main: addi sp,sp,-96 sd s3,56(sp) la s3,__stack_chk_guard...
.arch armv8-a .file "osoba.c" .text .section .rodata .align 3 .LC0: .string "./osoba.c" .align 3 .LC1: .string "Ubacio sam novcic, pary (%d)\n" .text .align 2 .global main .type main, %function main: .LFB6: .cfi_startproc stp x29, x30, [sp, -80]! .cfi_def_cfa_offset 80 .cfi_offset 29, -80 .cfi_offset 3...
.arch armv8-a .file "osoba.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "./osoba.c" .align 3 .LC1: .string "Ubacio sam novcic, pary (%d)\n" .text .align 2 .global main .type main, %function main: .LFB51: .cfi_startproc stp x29, x30, [sp, -96]! .cfi_def_cfa_offset 96 .cfi_off...
.arch armv8-a .file "osoba.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "./osoba.c" .align 3 .LC1: .string "Ubacio sam novcic, pary (%d)\n" .section .text.startup,"ax",@progbits .align 2 .p2align 4,,11 .global main .type main, %function main: .LFB51: .cfi_startproc stp x29, x...
.arch armv8-a .file "osoba.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "./osoba.c" .align 3 .LC1: .string "Ubacio sam novcic, pary (%d)\n" .section .text.startup,"ax",@progbits .align 2 .p2align 4,,11 .global main .type main, %function main: .LFB51: .cfi_startproc stp x29, x...
selection_sort.c
#include <stdio.h> #include <stdlib.h> void swap(int *, int *); /** * Selection sort algorithm. * * @param int input Array to sort * @param int n Number of data in search array * * @return void */ void selection_sort(int *input, int n) { int min; for (int i = 0; i < n - 1; i++) { min = i; ...
.file "selection_sort.c" .option pic .text .align 1 .globl selection_sort .type selection_sort, @function selection_sort: addi sp,sp,-48 sd ra,40(sp) sd s0,32(sp) addi s0,sp,48 sd a0,-40(s0) mv a5,a1 sw a5,-44(s0) sw zero,-24(s0) j .L2 .L7: lw a5,-24(s0) sw a5,-28(s0) lw a5,-24(s0) addiw a5,a5,1 sw ...
.file "selection_sort.c" .option pic .text .align 1 .globl selection_sort .type selection_sort, @function selection_sort: li a5,1 ble a1,a5,.L1 addi t1,a0,4 addiw t4,a1,-1 li a7,0 j .L6 .L4: addiw a4,a4,1 addi a3,a3,4 beq a1,a4,.L9 .L5: slli a5,a2,2 add a5,a0,a5 lw a6,0(a3) lw a5,0(a5) bge a6,a5,.L4...
.file "selection_sort.c" .option pic .text .align 1 .globl selection_sort .type selection_sort, @function selection_sort: addiw t4,a1,-1 ble t4,zero,.L1 addi t1,a0,4 li a7,0 .L6: mv t3,a7 addiw a7,a7,1 ble a1,a7,.L3 mv a3,t1 mv a4,a7 mv a2,t3 .L5: slli a5,a2,2 add a5,a0,a5 lw a6,0(a3) lw a5,0(a5) a...
.file "selection_sort.c" .option pic .text .align 1 .globl selection_sort .type selection_sort, @function selection_sort: addiw t0,a1,-1 addi t4,a0,4 li t3,0 ble t0,zero,.L1 .L6: mv t5,t3 addiw t3,t3,1 ble a1,t3,.L3 lw t6,-4(t4) mv a5,t4 mv a4,t3 mv a6,t6 mv a2,t5 j .L5 .L14: addiw a4,a4,1 add a7,a...
.arch armv8-a .file "selection_sort.c" .text .align 2 .global selection_sort .type selection_sort, %function selection_sort: .LFB6: .cfi_startproc stp x29, x30, [sp, -48]! .cfi_def_cfa_offset 48 .cfi_offset 29, -48 .cfi_offset 30, -40 mov x29, sp str x0, [sp, 24] str w1, [sp, 20] str wzr, [sp, 40] b .L2...
.arch armv8-a .file "selection_sort.c" .text .align 2 .global selection_sort .type selection_sort, %function selection_sort: .LFB39: .cfi_startproc sub w8, w1, #1 cmp w8, 0 ble .L1 mov x7, 1 mov x6, 0 b .L6 .L3: add x6, x6, 1 add x7, x7, 1 cmp w8, w6 ble .L1 .L6: mov w3, w6 cmp w1, w7 ble .L3 mov x...
.arch armv8-a .file "selection_sort.c" .text .align 2 .p2align 4,,11 .global selection_sort .type selection_sort, %function selection_sort: .LFB39: .cfi_startproc sub w8, w1, #1 cmp w8, 0 ble .L1 mov x7, 1 mov x6, 0 .p2align 3,,7 .L6: mov w3, w6 cmp w1, w7 ble .L3 mov x2, x7 .p2align 3,,7 .L5: ldr w...
.arch armv8-a .file "selection_sort.c" .text .align 2 .p2align 4,,11 .global selection_sort .type selection_sort, %function selection_sort: .LFB39: .cfi_startproc sub w12, w1, #1 add x9, x0, 4 mov w8, 0 cmp w12, 0 ble .L1 .p2align 3,,7 .L6: mov w10, w8 add w8, w8, 1 cmp w1, w8 ble .L3 ldr w11, [x9, -...
ast-print.c
// RUN: %clang_cc1 %s -ast-print | FileCheck %s // RUN: %clang_cc1 %s -ast-print | %clang_cc1 -fsyntax-only - typedef void func_typedef(); func_typedef xxx; typedef void func_t(int x); func_t a; struct blah { struct { struct { int b; }; }; }; int foo(const struct blah *b) { // CHECK: return b->b...
.file "ast-print.c" .option pic .text .align 1 .globl foo .type foo, @function foo: addi sp,sp,-32 sd s0,24(sp) addi s0,sp,32 sd a0,-24(s0) ld a5,-24(s0) lw a5,0(a5) mv a0,a5 ld s0,24(sp) addi sp,sp,32 jr ra .size foo, .-foo .align 1 .globl arr .type arr, @function arr: addi sp,sp,-32 sd s0,24(sp)...
.file "ast-print.c" .option pic .text .align 1 .globl foo .type foo, @function foo: lw a0,0(a0) ret .size foo, .-foo .align 1 .globl arr .type arr, @function arr: lw a0,8(a0) ret .size arr, .-arr .align 1 .globl rarr .type rarr, @function rarr: lw a0,8(a0) ret .size rarr, .-rarr .align 1 .globl v...
.file "ast-print.c" .option pic .text .align 1 .globl foo .type foo, @function foo: lw a0,0(a0) ret .size foo, .-foo .align 1 .globl arr .type arr, @function arr: lw a0,8(a0) ret .size arr, .-arr .align 1 .globl rarr .type rarr, @function rarr: lw a0,8(a0) ret .size rarr, .-rarr .align 1 .globl v...
.file "ast-print.c" .option pic .text .align 1 .globl foo .type foo, @function foo: lw a0,0(a0) ret .size foo, .-foo .align 1 .globl arr .type arr, @function arr: lw a0,8(a0) ret .size arr, .-arr .align 1 .globl rarr .type rarr, @function rarr: lw a0,8(a0) ret .size rarr, .-rarr .align 1 .globl v...
.arch armv8-a .file "ast-print.c" .text .align 2 .global foo .type foo, %function foo: .LFB0: .cfi_startproc sub sp, sp, #16 .cfi_def_cfa_offset 16 str x0, [sp, 8] ldr x0, [sp, 8] ldr w0, [x0] add sp, sp, 16 .cfi_def_cfa_offset 0 ret .cfi_endproc .LFE0: .size foo, .-foo .align 2 .global arr .type ar...
.arch armv8-a .file "ast-print.c" .text .align 2 .global foo .type foo, %function foo: .LFB0: .cfi_startproc ldr w0, [x0] ret .cfi_endproc .LFE0: .size foo, .-foo .align 2 .global arr .type arr, %function arr: .LFB1: .cfi_startproc ldr w0, [x0, 8] ret .cfi_endproc .LFE1: .size arr, .-arr .align 2 ....
.arch armv8-a .file "ast-print.c" .text .align 2 .p2align 4,,11 .global foo .type foo, %function foo: .LFB0: .cfi_startproc ldr w0, [x0] ret .cfi_endproc .LFE0: .size foo, .-foo .align 2 .p2align 4,,11 .global arr .type arr, %function arr: .LFB1: .cfi_startproc ldr w0, [x0, 8] ret .cfi_endproc .LFE1...
.arch armv8-a .file "ast-print.c" .text .align 2 .p2align 4,,11 .global foo .type foo, %function foo: .LFB0: .cfi_startproc ldr w0, [x0] ret .cfi_endproc .LFE0: .size foo, .-foo .align 2 .p2align 4,,11 .global arr .type arr, %function arr: .LFB1: .cfi_startproc ldr w0, [x0, 8] ret .cfi_endproc .LFE1...
gauss.c
#include <stdio.h> #include <stdlib.h> #define N 10 float *remontee(float A[N][N], float B[N], int n) { /******Implement the solution here******/ /***************************************/ float *x; x = malloc(sizeof(float) * n); x[n-1]=B[n-1]/A[n-1][n-1]; for(int i=n-2;i>=0;i--) { int s=0; for(int j=i+...
.file "gauss.c" .option pic .text .align 1 .globl remontee .type remontee, @function remontee: addi sp,sp,-80 sd ra,72(sp) sd s0,64(sp) addi s0,sp,80 sd a0,-56(s0) sd a1,-64(s0) mv a5,a2 sw a5,-68(s0) lw a5,-68(s0) slli a5,a5,2 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-24(s0) lw a5,-68(s0) slli a5,...
.file "gauss.c" .option pic .text .align 1 .globl remontee .type remontee, @function remontee: addi sp,sp,-48 sd ra,40(sp) sd s0,32(sp) sd s1,24(sp) sd s2,16(sp) sd s3,8(sp) mv s2,a0 mv s1,a1 mv s0,a2 slli s3,a2,2 mv a0,s3 call malloc@plt addi a4,s3,-4 add a5,s3,s0 slli a5,a5,3 addiw a2,s0,-1 sex...
.file "gauss.c" .option pic .text .align 1 .globl remontee .type remontee, @function remontee: addi sp,sp,-48 sd s3,8(sp) slli s3,a2,2 sd s0,32(sp) mv s0,a0 mv a0,s3 sd s1,24(sp) sd s2,16(sp) mv s1,a2 mv s2,a1 sd ra,40(sp) call malloc@plt add a5,s3,s1 addiw a7,s1,-1 slli a5,a5,3 addi s3,s3,-4 add...
.file "gauss.c" .option pic .text .align 1 .globl remontee .type remontee, @function remontee: addi sp,sp,-48 sd s3,8(sp) slli s3,a2,2 sd s0,32(sp) mv s0,a0 mv a0,s3 sd s1,24(sp) sd s2,16(sp) mv s1,a2 mv s2,a1 sd ra,40(sp) call malloc@plt add a5,s3,s1 addiw a7,s1,-1 slli a5,a5,3 addi s3,s3,-4 add...
.arch armv8-a .file "gauss.c" .text .align 2 .global remontee .type remontee, %function remontee: .LFB6: .cfi_startproc stp x29, x30, [sp, -80]! .cfi_def_cfa_offset 80 .cfi_offset 29, -80 .cfi_offset 30, -72 mov x29, sp str x0, [sp, 40] str x1, [sp, 32] str w2, [sp, 28] ldrsw x0, [sp, 28] lsl x0, x0, 2...
.arch armv8-a .file "gauss.c" .text .align 2 .global remontee .type remontee, %function remontee: .LFB39: .cfi_startproc stp x29, x30, [sp, -64]! .cfi_def_cfa_offset 64 .cfi_offset 29, -64 .cfi_offset 30, -56 mov x29, sp stp x19, x20, [sp, 16] stp x21, x22, [sp, 32] str x23, [sp, 48] .cfi_offset 19, -48...
.arch armv8-a .file "gauss.c" .text .align 2 .p2align 4,,11 .global remontee .type remontee, %function remontee: .LFB39: .cfi_startproc stp x29, x30, [sp, -48]! .cfi_def_cfa_offset 48 .cfi_offset 29, -48 .cfi_offset 30, -40 mov x29, sp stp x21, x22, [sp, 32] .cfi_offset 21, -16 .cfi_offset 22, -8 sbfiz...
.arch armv8-a .file "gauss.c" .text .align 2 .p2align 4,,11 .global remontee .type remontee, %function remontee: .LFB39: .cfi_startproc stp x29, x30, [sp, -48]! .cfi_def_cfa_offset 48 .cfi_offset 29, -48 .cfi_offset 30, -40 mov x29, sp stp x21, x22, [sp, 32] .cfi_offset 21, -16 .cfi_offset 22, -8 sbfiz...
3202.c
#include <stdio.h> #include <math.h> #include <string.h> int prime(int a) { int i=0,l=0,k=0; for (i=1;i<=a-1;i++) { k=a%i; if (k==0) l=l+1; } if (l==1) return 1; else return 0; } int main () {int num=0; scanf ("%d",&num); while (1) {num=num+1; if (prime(num)==1) break ;} printf ("...
.file "3202.c" .option pic .text .align 1 .globl prime .type prime, @function prime: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 mv a5,a0 sw a5,-36(s0) sw zero,-28(s0) sw zero,-24(s0) sw zero,-20(s0) li a5,1 sw a5,-28(s0) j .L2 .L4: lw a5,-36(s0) mv a4,a5 lw a5,-28(s0) remw a5,a4,a5 sw a5,-20(s0) l...
.file "3202.c" .option pic .text .align 1 .globl prime .type prime, @function prime: li a5,1 ble a0,a5,.L5 li a3,0 j .L4 .L3: addiw a5,a5,1 beq a0,a5,.L2 .L4: remw a4,a0,a5 bne a4,zero,.L3 addiw a3,a3,1 j .L3 .L5: li a3,0 .L2: addi a0,a3,-1 seqz a0,a0 ret .size prime, .-prime .section .rodata.str1...
.file "3202.c" .option pic .text .align 1 .globl prime .type prime, @function prime: li a5,1 ble a0,a5,.L5 li a3,0 .L4: remw a4,a0,a5 addiw a5,a5,1 bne a4,zero,.L3 addiw a3,a3,1 .L3: bne a0,a5,.L4 addi a0,a3,-1 seqz a0,a0 ret .L5: li a0,0 ret .size prime, .-prime .section .rodata.str1.8,"aMS",@prog...
.file "3202.c" .option pic .text .align 1 .globl prime .type prime, @function prime: li a5,1 ble a0,a5,.L5 li a3,0 .L4: remw a4,a0,a5 addiw a5,a5,1 bne a4,zero,.L3 addiw a3,a3,1 .L3: bne a5,a0,.L4 addi a0,a3,-1 seqz a0,a0 ret .L5: li a0,0 ret .size prime, .-prime .section .rodata.str1.8,"aMS",@prog...
.arch armv8-a .file "3202.c" .text .align 2 .global prime .type prime, %function prime: .LFB0: .cfi_startproc sub sp, sp, #32 .cfi_def_cfa_offset 32 str w0, [sp, 12] str wzr, [sp, 20] str wzr, [sp, 24] str wzr, [sp, 28] mov w0, 1 str w0, [sp, 20] b .L2 .L4: ldr w0, [sp, 12] ldr w1, [sp, 20] sdiv w2, ...
.arch armv8-a .file "3202.c" .text .align 2 .global prime .type prime, %function prime: .LFB35: .cfi_startproc cmp w0, 1 ble .L5 mov w3, 0 mov w1, 1 .L4: sdiv w2, w0, w1 msub w2, w2, w1, w0 cmp w2, 0 cinc w3, w3, eq add w1, w1, 1 cmp w0, w1 bne .L4 .L2: cmp w3, 1 cset w0, eq ret .L5: mov w3, 0 b ...
.arch armv8-a .file "3202.c" .text .align 2 .p2align 4,,11 .global prime .type prime, %function prime: .LFB35: .cfi_startproc cmp w0, 1 ble .L5 mov w3, 0 mov w1, 1 .p2align 3,,7 .L4: sdiv w2, w0, w1 msub w2, w2, w1, w0 add w1, w1, 1 cmp w2, 0 cinc w3, w3, eq cmp w0, w1 bne .L4 cmp w3, 1 cset w0, e...
.arch armv8-a .file "3202.c" .text .align 2 .p2align 4,,11 .global prime .type prime, %function prime: .LFB35: .cfi_startproc cmp w0, 1 ble .L5 mov w3, 0 mov w1, 1 .p2align 3,,7 .L4: sdiv w2, w0, w1 msub w2, w2, w1, w0 add w1, w1, 1 cmp w2, 0 cinc w3, w3, eq cmp w1, w0 bne .L4 cmp w3, 1 cset w0, e...
watchpoint-reuse-slot.c
/* This testcase is part of GDB, the GNU debugger. Copyright 2014-2021 Free Software Foundation, Inc. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or ...
.file "watchpoint-reuse-slot.c" .option pic .text .globl buf .bss .align 3 .type buf, @object .size buf, 16 buf: .zero 16 .text .align 1 .globl main .type main, @function main: addi sp,sp,-32 sd s0,24(sp) addi s0,sp,32 sw zero,-20(s0) sw zero,-20(s0) j .L2 .L3: lw a5,-20(s0) sext.w a5,a5 addiw a5,...
.file "watchpoint-reuse-slot.c" .option pic .text .align 1 .globl main .type main, @function main: addi sp,sp,-16 sw zero,12(sp) sw zero,12(sp) lw a4,12(sp) sext.w a4,a4 li a5,98304 addi a5,a5,1695 bgt a4,a5,.L2 mv a4,a5 .L3: lw a5,12(sp) addiw a5,a5,1 sw a5,12(sp) lw a5,12(sp) sext.w a5,a5 ble a5,...
.file "watchpoint-reuse-slot.c" .option pic .text .section .text.startup,"ax",@progbits .align 1 .globl main .type main, @function main: addi sp,sp,-16 sw zero,12(sp) sw zero,12(sp) lw a5,12(sp) li a4,98304 addi a4,a4,1695 bgt a5,a4,.L2 .L3: lw a5,12(sp) addiw a5,a5,1 sw a5,12(sp) lw a5,12(sp) ble a5...
.file "watchpoint-reuse-slot.c" .option pic .text .section .text.startup,"ax",@progbits .align 1 .globl main .type main, @function main: addi sp,sp,-16 sw zero,12(sp) sw zero,12(sp) lw a5,12(sp) li a4,98304 addi a4,a4,1695 bgt a5,a4,.L2 .L3: lw a5,12(sp) addiw a5,a5,1 sw a5,12(sp) lw a5,12(sp) ble a5...
.arch armv8-a .file "watchpoint-reuse-slot.c" .text .global buf .bss .align 3 .type buf, %object .size buf, 16 buf: .zero 16 .text .align 2 .global main .type main, %function main: .LFB0: .cfi_startproc sub sp, sp, #16 .cfi_def_cfa_offset 16 str wzr, [sp, 12] str wzr, [sp, 12] b .L2 .L3: ldr w0, [sp...
.arch armv8-a .file "watchpoint-reuse-slot.c" .text .align 2 .global main .type main, %function main: .LFB0: .cfi_startproc sub sp, sp, #16 .cfi_def_cfa_offset 16 str wzr, [sp, 12] str wzr, [sp, 12] ldr w1, [sp, 12] mov w0, 34463 movk w0, 0x1, lsl 16 cmp w1, w0 bgt .L2 mov w1, w0 .L3: ldr w0, [sp, 12]...
.arch armv8-a .file "watchpoint-reuse-slot.c" .text .section .text.startup,"ax",@progbits .align 2 .p2align 4,,11 .global main .type main, %function main: .LFB0: .cfi_startproc sub sp, sp, #16 .cfi_def_cfa_offset 16 mov w1, 34463 movk w1, 0x1, lsl 16 str wzr, [sp, 12] str wzr, [sp, 12] ldr w0, [sp, 12] ...
.arch armv8-a .file "watchpoint-reuse-slot.c" .text .section .text.startup,"ax",@progbits .align 2 .p2align 4,,11 .global main .type main, %function main: .LFB0: .cfi_startproc sub sp, sp, #16 .cfi_def_cfa_offset 16 mov w1, 34463 movk w1, 0x1, lsl 16 str wzr, [sp, 12] str wzr, [sp, 12] ldr w0, [sp, 12] ...
sse2-extract-1.c
/* { dg-do run } */ /* { dg-options "-O2 -msse2" } */ /* { dg-require-effective-target sse2_runtime } */ extern void abort (void); typedef unsigned long long uint64_t; #define vector(elcount, type) \ __attribute__((vector_size((elcount)*sizeof(type)))) type #define FN(elcount, type, idx) \ __attribute__((noinline, ...
.file "sse2-extract-1.c" .option pic .text .align 1 .globl fdouble2_0 .type fdouble2_0, @function fdouble2_0: addi sp,sp,-32 sd s0,24(sp) addi s0,sp,32 sd a0,-32(s0) sd a1,-24(s0) fld fa4,-32(s0) lla a5,.LC0 fld fa5,0(a5) fadd.d fa5,fa4,fa5 fmv.d fa0,fa5 ld s0,24(sp) addi sp,sp,32 jr ra .size fdoubl...
.file "sse2-extract-1.c" .option pic .text .align 1 .globl fdouble2_0 .type fdouble2_0, @function fdouble2_0: addi sp,sp,-16 fld fa0,.LC0,a5 fmv.d.x fa5,a0 fadd.d fa0,fa5,fa0 addi sp,sp,16 jr ra .size fdouble2_0, .-fdouble2_0 .align 1 .globl fdouble2_1 .type fdouble2_1, @function fdouble2_1: addi sp,sp...
.file "sse2-extract-1.c" .option pic .text .align 1 .globl fdouble2_0 .type fdouble2_0, @function fdouble2_0: fmv.d.x fa0,a0 addi sp,sp,-16 fld fa5,.LC0,a5 fadd.d fa0,fa0,fa5 addi sp,sp,16 jr ra .size fdouble2_0, .-fdouble2_0 .align 1 .globl fdouble2_1 .type fdouble2_1, @function fdouble2_1: fmv.d.x fa...
.file "sse2-extract-1.c" .option pic .text .align 1 .globl fdouble2_0 .type fdouble2_0, @function fdouble2_0: fmv.d.x fa0,a0 addi sp,sp,-16 fld fa5,.LC0,a5 fadd.d fa0,fa0,fa5 addi sp,sp,16 jr ra .size fdouble2_0, .-fdouble2_0 .align 1 .globl fdouble2_1 .type fdouble2_1, @function fdouble2_1: fmv.d.x fa...
.arch armv8-a .file "sse2-extract-1.c" .text .align 2 .global fdouble2_0 .type fdouble2_0, %function fdouble2_0: .LFB0: .cfi_startproc sub sp, sp, #16 .cfi_def_cfa_offset 16 str q0, [sp] ldr d1, [sp] fmov d0, 1.0e+0 fadd d0, d1, d0 add sp, sp, 16 .cfi_def_cfa_offset 0 ret .cfi_endproc .LFE0: .size fdo...
.arch armv8-a .file "sse2-extract-1.c" .text .align 2 .global fdouble2_0 .type fdouble2_0, %function fdouble2_0: .LFB0: .cfi_startproc fmov d1, 1.0e+0 fadd d0, d0, d1 ret .cfi_endproc .LFE0: .size fdouble2_0, .-fdouble2_0 .align 2 .global fdouble2_1 .type fdouble2_1, %function fdouble2_1: .LFB1: .cfi_st...
.arch armv8-a .file "sse2-extract-1.c" .text .align 2 .p2align 4,,11 .global fdouble2_0 .type fdouble2_0, %function fdouble2_0: .LFB0: .cfi_startproc fmov d1, 1.0e+0 fadd d0, d0, d1 ret .cfi_endproc .LFE0: .size fdouble2_0, .-fdouble2_0 .align 2 .p2align 4,,11 .global fdouble2_1 .type fdouble2_1, %func...
.arch armv8-a .file "sse2-extract-1.c" .text .align 2 .p2align 4,,11 .global fdouble2_0 .type fdouble2_0, %function fdouble2_0: .LFB0: .cfi_startproc fmov d1, 1.0e+0 fadd d0, d0, d1 ret .cfi_endproc .LFE0: .size fdouble2_0, .-fdouble2_0 .align 2 .p2align 4,,11 .global fdouble2_1 .type fdouble2_1, %func...
ttas-5.c
#include <stdio.h> #include <stdlib.h> #include <stdint.h> #include <pthread.h> #include <stdatomic.h> #include <assert.h> // ttaslock.h // struct ttaslock_s { atomic_int state; }; typedef struct ttaslock_s ttaslock_t; static inline void ttaslock_init(struct ttaslock_s *l); static inline void ttaslock_acquire(str...
.file "ttas-5.c" .option pic .text .align 1 .type ttaslock_init, @function ttaslock_init: addi sp,sp,-64 sd ra,56(sp) sd s0,48(sp) addi s0,sp,64 sd a0,-56(s0) la a5,__stack_chk_guard ld a4, 0(a5) sd a4, -24(s0) li a4, 0 ld a5,-56(s0) sd a5,-32(s0) sw zero,-36(s0) lw a5,-36(s0) sext.w a4,a5 ld a5,-32...
.file "ttas-5.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "programs/ttas-5.c" .align 3 .LC1: .string "r == index" .text .align 1 .globl thread_n .type thread_n, @function thread_n: lla a4,.LANCHOR0 li a3,1 .L2: lw a5,0(a4) sext.w a5,a5 bne a5,zero,.L2 mv a5,a3...
.file "ttas-5.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "programs/ttas-5.c" .align 3 .LC1: .string "r == index" .text .align 1 .globl thread_n .type thread_n, @function thread_n: lla a4,.LANCHOR0 li a3,1 .L2: lw a5,0(a4) bne a5,zero,.L2 mv a5,a3 amoswap.w.aq...
.file "ttas-5.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "programs/ttas-5.c" .align 3 .LC1: .string "r == index" .text .align 1 .globl thread_n .type thread_n, @function thread_n: lla a4,.LANCHOR0 li a3,1 .L2: lw a5,0(a4) bne a5,zero,.L2 mv a5,a3 amoswap.w.aq...
.arch armv8-a .file "ttas-5.c" .text .align 2 .type ttaslock_init, %function ttaslock_init: .LFB6: .cfi_startproc stp x29, x30, [sp, -64]! .cfi_def_cfa_offset 64 .cfi_offset 29, -64 .cfi_offset 30, -56 mov x29, sp str x0, [sp, 24] adrp x0, :got:__stack_chk_guard ldr x0, [x0, #:got_lo12:__stack_chk_guard] ...
.arch armv8-a .file "ttas-5.c" .text .global __aarch64_swp4_acq .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "programs/ttas-5.c" .align 3 .LC1: .string "r == index" .text .align 2 .global thread_n .type thread_n, %function thread_n: .LFB45: .cfi_startproc stp x29, x30, [sp, -48]! .cf...
.arch armv8-a .file "ttas-5.c" .text .global __aarch64_swp4_acq .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "programs/ttas-5.c" .align 3 .LC1: .string "r == index" .text .align 2 .p2align 4,,11 .global thread_n .type thread_n, %function thread_n: .LFB45: .cfi_startproc stp x29, x30,...
.arch armv8-a .file "ttas-5.c" .text .global __aarch64_swp4_acq .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "programs/ttas-5.c" .align 3 .LC1: .string "r == index" .text .align 2 .p2align 4,,11 .global thread_n .type thread_n, %function thread_n: .LFB45: .cfi_startproc stp x29, x30,...
redundant_co_20.c
/* This example is taken from the TRACER benchmarks * https://doi.org/10.1145/3276505 */ // Adapted for the tool PSChecker #include <pthread.h> #define N 20 int x; void *thread1(void *arg) { int i; for (i=0; i<N; i++) rlx_write_ps(x,1); return NULL; } void *thread2(void *arg) { int i; for (i=0; i<N; i+...
.file "redundant_co_20.c" .option pic .text .globl x .bss .align 2 .type x, @object .size x, 4 x: .zero 4 .text .align 1 .globl thread1 .type thread1, @function thread1: addi sp,sp,-48 sd ra,40(sp) sd s0,32(sp) addi s0,sp,48 sd a0,-40(s0) sw zero,-20(s0) j .L2 .L3: lla a5,x lw a5,0(a5) li a1,1 m...
.file "redundant_co_20.c" .option pic .text .align 1 .globl thread1 .type thread1, @function thread1: addi sp,sp,-32 sd ra,24(sp) sd s0,16(sp) sd s1,8(sp) li s0,20 lla s1,.LANCHOR0 .L2: li a1,1 lw a0,0(s1) call rlx_write_ps@plt addiw s0,s0,-1 bne s0,zero,.L2 li a0,0 ld ra,24(sp) ld s0,16(sp) ld s1,...
.file "redundant_co_20.c" .option pic .text .align 1 .globl thread1 .type thread1, @function thread1: addi sp,sp,-32 sd s0,16(sp) sd s1,8(sp) sd ra,24(sp) li s0,20 lla s1,.LANCHOR0 .L2: lw a0,0(s1) addiw s0,s0,-1 li a1,1 call rlx_write_ps@plt bne s0,zero,.L2 ld ra,24(sp) ld s0,16(sp) ld s1,8(sp) li...
.file "redundant_co_20.c" .option pic .text .align 1 .globl thread1 .type thread1, @function thread1: addi sp,sp,-32 sd s0,16(sp) sd s1,8(sp) sd ra,24(sp) li s0,20 lla s1,.LANCHOR0 .L2: lw a0,0(s1) addiw s0,s0,-1 li a1,1 call rlx_write_ps@plt bne s0,zero,.L2 ld ra,24(sp) ld s0,16(sp) ld s1,8(sp) li...
.arch armv8-a .file "redundant_co_20.c" .text .global x .bss .align 2 .type x, %object .size x, 4 x: .zero 4 .text .align 2 .global thread1 .type thread1, %function thread1: .LFB0: .cfi_startproc stp x29, x30, [sp, -48]! .cfi_def_cfa_offset 48 .cfi_offset 29, -48 .cfi_offset 30, -40 mov x29, sp str ...
.arch armv8-a .file "redundant_co_20.c" .text .align 2 .global thread1 .type thread1, %function thread1: .LFB1: .cfi_startproc stp x29, x30, [sp, -48]! .cfi_def_cfa_offset 48 .cfi_offset 29, -48 .cfi_offset 30, -40 mov x29, sp stp x19, x20, [sp, 16] str x21, [sp, 32] .cfi_offset 19, -32 .cfi_offset 20, ...
.arch armv8-a .file "redundant_co_20.c" .text .align 2 .p2align 4,,11 .global thread1 .type thread1, %function thread1: .LFB1: .cfi_startproc stp x29, x30, [sp, -32]! .cfi_def_cfa_offset 32 .cfi_offset 29, -32 .cfi_offset 30, -24 mov x29, sp stp x19, x20, [sp, 16] .cfi_offset 19, -16 .cfi_offset 20, -8 ...
.arch armv8-a .file "redundant_co_20.c" .text .align 2 .p2align 4,,11 .global thread1 .type thread1, %function thread1: .LFB1: .cfi_startproc stp x29, x30, [sp, -32]! .cfi_def_cfa_offset 32 .cfi_offset 29, -32 .cfi_offset 30, -24 mov x29, sp stp x19, x20, [sp, 16] .cfi_offset 19, -16 .cfi_offset 20, -8 ...
paranoia.c
/* $Source$ * $State$ * $Revision$ */ /* This is a solo paranoia game taken from the Jan/Feb issue (No 77) of "SpaceGamer/FantasyGamer" magazine. Article by Sam Shirley. Implemented in C on Vax 11/780 under UNIX by Tim Lister Very slightly modernised to run on 2007-era (!) compilers by David Given...
.file "paranoia.c" .option pic .text .globl clone .data .align 2 .type clone, @object .size clone, 4 clone: .word 1 .globl page .align 2 .type page, @object .size page, 4 page: .word 1 .globl computer_request .bss .align 2 .type computer_request, @object .size computer_request, 4 computer_request: ....
.file "paranoia.c" .option pic .text .align 1 .globl get_char .type get_char, @function get_char: addi sp,sp,-32 sd ra,24(sp) sd s0,16(sp) sd s1,8(sp) sd s2,0(sp) la a5,stdout ld a0,0(a5) call fflush@plt la a5,stdin ld a0,0(a5) call getc@plt andi s2,a0,0xff li a5,10 beq s2,a5,.L2 la s1,stdin li s0...
.file "paranoia.c" .option pic .text .align 1 .globl get_char .type get_char, @function get_char: la a5,stdout ld a0,0(a5) addi sp,sp,-32 sd ra,24(sp) sd s0,16(sp) sd s2,0(sp) sd s1,8(sp) la s0,stdin call fflush@plt ld a0,0(s0) call getc@plt andi s2,a0,0xff li a5,10 beq s2,a5,.L2 li s1,10 .L3: ld ...
.file "paranoia.c" .option pic .text .align 1 .globl get_char .type get_char, @function get_char: la a5,stdout ld a0,0(a5) addi sp,sp,-32 sd ra,24(sp) sd s0,16(sp) sd s2,0(sp) sd s1,8(sp) la s0,stdin call fflush@plt ld a0,0(s0) call getc@plt andi s2,a0,0xff li a5,10 beq s2,a5,.L2 li s1,10 .L3: ld ...
.arch armv8-a .file "paranoia.c" .text .global clone .data .align 2 .type clone, %object .size clone, 4 clone: .word 1 .global page .align 2 .type page, %object .size page, 4 page: .word 1 .global computer_request .bss .align 2 .type computer_request, %object .size computer_request, 4 computer_reques...
.arch armv8-a .file "paranoia.c" .text .align 2 .global get_char .type get_char, %function get_char: .LFB23: .cfi_startproc stp x29, x30, [sp, -32]! .cfi_def_cfa_offset 32 .cfi_offset 29, -32 .cfi_offset 30, -24 mov x29, sp stp x19, x20, [sp, 16] .cfi_offset 19, -16 .cfi_offset 20, -8 adrp x0, :got:stdo...
.arch armv8-a .file "paranoia.c" .text .align 2 .p2align 4,,11 .global get_char .type get_char, %function get_char: .LFB23: .cfi_startproc stp x29, x30, [sp, -32]! .cfi_def_cfa_offset 32 .cfi_offset 29, -32 .cfi_offset 30, -24 adrp x0, :got:stdout mov x29, sp ldr x0, [x0, #:got_lo12:stdout] stp x19, x20...
.arch armv8-a .file "paranoia.c" .text .align 2 .p2align 4,,11 .global get_char .type get_char, %function get_char: .LFB23: .cfi_startproc stp x29, x30, [sp, -32]! .cfi_def_cfa_offset 32 .cfi_offset 29, -32 .cfi_offset 30, -24 adrp x0, :got:stdout mov x29, sp ldr x0, [x0, #:got_lo12:stdout] stp x19, x20...
mips-features.c
// Check handling MIPS specific features options. // // -mabicalls // RUN: %clang -target mips-linux-gnu -### -c %s -mno-abicalls -mabicalls 2>&1 \ // RUN: | FileCheck --check-prefix=CHECK-MABICALLS %s // CHECK-MABICALLS: "-target-feature" "-noabicalls" // // -mno-abicalls // RUN: %clang -target mips-linux-gnu -### -...
.file "mips-features.c" .option pic .text .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.file "mips-features.c" .option pic .text .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.file "mips-features.c" .option pic .text .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.file "mips-features.c" .option pic .text .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.arch armv8-a .file "mips-features.c" .text .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.arch armv8-a .file "mips-features.c" .text .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.arch armv8-a .file "mips-features.c" .text .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.arch armv8-a .file "mips-features.c" .text .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
PatternX.c
#include<stdio.h> #include<string.h> int main() { char str[1000]; int i,j; scanf("%s",&str); //printf("%s",str); for(i=0;i<strlen(str);i++) { for(j=0;j<strlen(str);j++) { if((i==j) || i+j==strlen(str)-1) printf("%c",str[j]); else ...
.file "PatternX.c" .option pic .text .section .rodata .align 3 .LC0: .string "%s" .text .align 1 .globl main .type main, @function main: addi sp,sp,-1056 sd ra,1048(sp) sd s0,1040(sp) sd s1,1032(sp) addi s0,sp,1056 la a5,__stack_chk_guard ld a4, 0(a5) sd a4, -40(s0) li a4, 0 addi a5,s0,-1040 mv a1,...
.file "PatternX.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "%s" .text .align 1 .globl main .type main, @function main: addi sp,sp,-1056 sd ra,1048(sp) sd s0,1040(sp) sd s1,1032(sp) sd s2,1024(sp) sd s3,1016(sp) sd s4,1008(sp) la a5,__stack_chk_guard ld a4, 0...
.file "PatternX.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "%s" .section .text.startup,"ax",@progbits .align 1 .globl main .type main, @function main: addi sp,sp,-1072 sd s3,1032(sp) sd s4,1024(sp) mv s3,sp la s4,__stack_chk_guard mv a1,s3 lla a0,.LC0 ld a5, ...
.file "PatternX.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "%s" .section .text.startup,"ax",@progbits .align 1 .globl main .type main, @function main: addi sp,sp,-1072 sd s3,1032(sp) sd s4,1024(sp) mv s3,sp la s4,__stack_chk_guard mv a1,s3 lla a0,.LC0 ld a5, ...
.arch armv8-a .file "PatternX.c" .text .section .rodata .align 3 .LC0: .string "%s" .text .align 2 .global main .type main, %function main: .LFB0: .cfi_startproc sub sp, sp, #1056 .cfi_def_cfa_offset 1056 stp x29, x30, [sp] .cfi_offset 29, -1056 .cfi_offset 30, -1048 mov x29, sp str x19, [sp, 16] .cf...
.arch armv8-a .file "PatternX.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "%s" .text .align 2 .global main .type main, %function main: .LFB35: .cfi_startproc sub sp, sp, #1072 .cfi_def_cfa_offset 1072 stp x29, x30, [sp] .cfi_offset 29, -1072 .cfi_offset 30, -1064 mov x29, ...
.arch armv8-a .file "PatternX.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "%s" .section .text.startup,"ax",@progbits .align 2 .p2align 4,,11 .global main .type main, %function main: .LFB35: .cfi_startproc sub sp, sp, #1056 .cfi_def_cfa_offset 1056 adrp x2, :got:__stack_chk_g...
.arch armv8-a .file "PatternX.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "%s" .section .text.startup,"ax",@progbits .align 2 .p2align 4,,11 .global main .type main, %function main: .LFB35: .cfi_startproc sub sp, sp, #1056 .cfi_def_cfa_offset 1056 adrp x2, :got:__stack_chk_g...
HelloWorld-loop-nice-5.c
#include <stdio.h> int main() { int k; printf("HelloWorld!\n"); nice(-5); while(1); k=k+1; return 0; }
.file "HelloWorld-loop-nice-5.c" .option pic .text .section .rodata .align 3 .LC0: .string "HelloWorld!" .text .align 1 .globl main .type main, @function main: addi sp,sp,-16 sd ra,8(sp) sd s0,0(sp) addi s0,sp,16 lla a0,.LC0 call puts@plt li a0,-5 call nice@plt .L2: j .L2 .size main, .-main .ident ...
.file "HelloWorld-loop-nice-5.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "HelloWorld!" .text .align 1 .globl main .type main, @function main: addi sp,sp,-16 sd ra,8(sp) lla a0,.LC0 call puts@plt li a0,-5 call nice@plt .L2: j .L2 .size main, .-main .ident "GC...
.file "HelloWorld-loop-nice-5.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "HelloWorld!" .section .text.startup,"ax",@progbits .align 1 .globl main .type main, @function main: addi sp,sp,-16 lla a0,.LC0 sd ra,8(sp) call puts@plt li a0,-5 call nice@plt .L2: j .L2...
.file "HelloWorld-loop-nice-5.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "HelloWorld!" .section .text.startup,"ax",@progbits .align 1 .globl main .type main, @function main: addi sp,sp,-16 lla a0,.LC0 sd ra,8(sp) call puts@plt li a0,-5 call nice@plt .L2: j .L2...
.arch armv8-a .file "HelloWorld-loop-nice-5.c" .text .section .rodata .align 3 .LC0: .string "HelloWorld!" .text .align 2 .global main .type main, %function main: .LFB0: .cfi_startproc stp x29, x30, [sp, -16]! .cfi_def_cfa_offset 16 .cfi_offset 29, -16 .cfi_offset 30, -8 mov x29, sp adrp x0, .LC0 add ...
.arch armv8-a .file "HelloWorld-loop-nice-5.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "HelloWorld!" .text .align 2 .global main .type main, %function main: .LFB23: .cfi_startproc stp x29, x30, [sp, -16]! .cfi_def_cfa_offset 16 .cfi_offset 29, -16 .cfi_offset 30, -8 mov x2...
.arch armv8-a .file "HelloWorld-loop-nice-5.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "HelloWorld!" .section .text.startup,"ax",@progbits .align 2 .p2align 4,,11 .global main .type main, %function main: .LFB23: .cfi_startproc stp x29, x30, [sp, -16]! .cfi_def_cfa_offset 16 ...
.arch armv8-a .file "HelloWorld-loop-nice-5.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "HelloWorld!" .section .text.startup,"ax",@progbits .align 2 .p2align 4,,11 .global main .type main, %function main: .LFB23: .cfi_startproc stp x29, x30, [sp, -16]! .cfi_def_cfa_offset 16 ...
test_21.c
//quartz2963_6801/_tests/_group_1/_test_7.c //+1.0017E305 5 +1.2159E306 +1.6163E305 +1.7957E41 5 -1.6196E-307 +1.4187E-307 +1.8598E306 +1.7620E-307 +0.0 +0.0 -1.7235E-313 -1.6086E305 -1.9217E131 // /* This is a automatically generated test. Do not modify */ #include <stdio.h> #include <stdlib.h> #include <math.h> vo...
.file "test_21.c" .option pic .text .section .rodata .align 3 .LC9: .string "%.17g\n" .text .align 1 .globl compute .type compute, @function compute: addi sp,sp,-144 sd ra,136(sp) sd s0,128(sp) addi s0,sp,144 fsd fa0,-40(s0) fsd fa1,-56(s0) fsd fa2,-64(s0) fsd fa3,-72(s0) fsd fa4,-80(s0) fsd fa5,-88...
.file "test_21.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC8: .string "%.17g\n" .text .align 1 .globl compute .type compute, @function compute: addi sp,sp,-160 sd ra,152(sp) sd s0,144(sp) sd s1,136(sp) sd s2,128(sp) sd s3,120(sp) sd s4,112(sp) sd s5,104(sp) sd s6,96(sp)...
.file "test_21.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC8: .string "%.17g\n" .text .align 1 .globl compute .type compute, @function compute: addi sp,sp,-144 sd s0,128(sp) fld fa4,.LC0,s0 fmadd.d fa2,fa2,fa4,fa3 fld fa3,.LC1,s0 fld fa4,.LC2,s0 fsd fs0,88(sp) fmv.d fs0,...
.file "test_21.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC8: .string "%.17g\n" .text .align 1 .globl compute .type compute, @function compute: addi sp,sp,-144 sd s0,128(sp) fld fa4,.LC0,s0 fmadd.d fa2,fa2,fa4,fa3 fld fa3,.LC1,s0 fld fa4,.LC2,s0 fsd fs0,88(sp) fmv.d fs0,...
.arch armv8-a .file "test_21.c" .text .section .rodata .align 3 .LC0: .string "%.17g\n" .text .align 2 .global compute .type compute, %function compute: .LFB6: .cfi_startproc stp x29, x30, [sp, -112]! .cfi_def_cfa_offset 112 .cfi_offset 29, -112 .cfi_offset 30, -104 mov x29, sp str d0, [sp, 88] str w0...
.arch armv8-a .file "test_21.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "%.17g\n" .text .align 2 .global compute .type compute, %function compute: .LFB39: .cfi_startproc stp x29, x30, [sp, -128]! .cfi_def_cfa_offset 128 .cfi_offset 29, -128 .cfi_offset 30, -120 mov x29, sp...
.arch armv8-a .file "test_21.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "%.17g\n" .text .align 2 .p2align 4,,11 .global compute .type compute, %function compute: .LFB39: .cfi_startproc stp x29, x30, [sp, -144]! .cfi_def_cfa_offset 144 .cfi_offset 29, -144 .cfi_offset 30, -...
.arch armv8-a .file "test_21.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "%.17g\n" .text .align 2 .p2align 4,,11 .global compute .type compute, %function compute: .LFB39: .cfi_startproc stp x29, x30, [sp, -144]! .cfi_def_cfa_offset 144 .cfi_offset 29, -144 .cfi_offset 30, -...
test4.c
#include <stdio.h> #include <stdbool.h> int main() { int i, j, n = 5, d[n][n], x; bool found; for (size_t i = 0; i < n; i++) { for (size_t j = 0; j < n; j++) { printf("Digite um valor para D(%d,%d): ", i, j); scanf("%d", &d[i][j]); } } printf("D...
.file "test4.c" .option pic .text .section .rodata .align 3 .LC0: .string "Digite um valor para D(%d,%d): " .align 3 .LC1: .string "%d" .align 3 .LC2: .string "Digite um valor para procurar: " .align 3 .LC3: .string "Valor %d existe." .align 3 .LC4: .string "Valor %d n\303\243o existe." .text .align 1 ...
.file "test4.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "Digite um valor para D(%d,%d): " .align 3 .LC1: .string "%d" .align 3 .LC2: .string "Digite um valor para procurar: " .align 3 .LC3: .string "Valor %d existe." .text .align 1 .globl main .type main, @func...
.file "test4.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "Digite um valor para D(%d,%d): " .align 3 .LC1: .string "%d" .align 3 .LC2: .string "Digite um valor para procurar: " .align 3 .LC3: .string "Valor %d existe." .section .text.startup,"ax",@progbits .align 1...
.file "test4.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "Digite um valor para D(%d,%d): " .align 3 .LC1: .string "%d" .align 3 .LC2: .string "Digite um valor para procurar: " .align 3 .LC3: .string "Valor %d existe." .section .text.startup,"ax",@progbits .align 1...
.arch armv8-a .file "test4.c" .text .section .rodata .align 3 .LC0: .string "Digite um valor para D(%d,%d): " .align 3 .LC1: .string "%d" .align 3 .LC2: .string "Digite um valor para procurar: " .align 3 .LC3: .string "Valor %d existe." .align 3 .LC4: .string "Valor %d n\303\243o existe." .text .align 2...
.arch armv8-a .file "test4.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "Digite um valor para D(%d,%d): " .align 3 .LC1: .string "%d" .align 3 .LC2: .string "Digite um valor para procurar: " .align 3 .LC3: .string "Valor %d existe." .text .align 2 .global main .type main, %f...
.arch armv8-a .file "test4.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "Digite um valor para D(%d,%d): " .align 3 .LC1: .string "%d" .align 3 .LC2: .string "Digite um valor para procurar: " .align 3 .LC3: .string "Valor %d existe." .section .text.startup,"ax",@progbits .align...
.arch armv8-a .file "test4.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "Digite um valor para D(%d,%d): " .align 3 .LC1: .string "%d" .align 3 .LC2: .string "Digite um valor para procurar: " .align 3 .LC3: .string "Valor %d existe." .section .text.startup,"ax",@progbits .align...
typedefbounds.c
// RUN: 3c -alltypes -addcr %s -- | FileCheck -match-full-lines -check-prefixes="CHECK_ALL","CHECK" %s // RUN: 3c --addcr --alltypes %s -- | %clang_cc1 -fcheckedc-extension -x c - // // 3c -alltypes -output-postfix=checked %s // 3c -alltypes %S/typedefs.checked.c -- | diff %S/typedefs.checked.c - // rm %S/typedefs.che...
.file "typedefbounds.c" .option pic .text .section .rodata .align 3 .LC0: .string "hello" .text .align 1 .globl foo .type foo, @function foo: addi sp,sp,-32 sd s0,24(sp) addi s0,sp,32 lla a5,.LC0 sd a5,-24(s0) ld a5,-24(s0) lbu a5,2(a5) sb a5,-25(s0) nop ld s0,24(sp) addi sp,sp,32 jr ra .size foo...
.file "typedefbounds.c" .option pic .text .align 1 .globl foo .type foo, @function foo: ret .size foo, .-foo .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.file "typedefbounds.c" .option pic .text .align 1 .globl foo .type foo, @function foo: ret .size foo, .-foo .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.file "typedefbounds.c" .option pic .text .align 1 .globl foo .type foo, @function foo: ret .size foo, .-foo .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.arch armv8-a .file "typedefbounds.c" .text .section .rodata .align 3 .LC0: .string "hello" .text .align 2 .global foo .type foo, %function foo: .LFB0: .cfi_startproc sub sp, sp, #16 .cfi_def_cfa_offset 16 adrp x0, .LC0 add x0, x0, :lo12:.LC0 str x0, [sp, 8] ldr x0, [sp, 8] ldrb w0, [x0, 2] strb w0, ...
.arch armv8-a .file "typedefbounds.c" .text .align 2 .global foo .type foo, %function foo: .LFB0: .cfi_startproc ret .cfi_endproc .LFE0: .size foo, .-foo .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.arch armv8-a .file "typedefbounds.c" .text .align 2 .p2align 4,,11 .global foo .type foo, %function foo: .LFB0: .cfi_startproc ret .cfi_endproc .LFE0: .size foo, .-foo .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.arch armv8-a .file "typedefbounds.c" .text .align 2 .p2align 4,,11 .global foo .type foo, %function foo: .LFB0: .cfi_startproc ret .cfi_endproc .LFE0: .size foo, .-foo .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
Main.c
#include <stdint.h> #include <stdio.h> #include <stdlib.h> struct Vector; // { } // typedef int *createArray(unsigned int length, int value) { int *data = (int *)malloc(length * sizeof(int)); if (data == NULL) { return NULL; } for (unsigned int i = 0; i < length; i++) { data...
.file "Main.c" .option pic .text .align 1 .globl createArray .type createArray, @function createArray: addi sp,sp,-48 sd ra,40(sp) sd s0,32(sp) addi s0,sp,48 mv a5,a0 mv a4,a1 sw a5,-36(s0) mv a5,a4 sw a5,-40(s0) lwu a5,-36(s0) slli a5,a5,2 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-24(s0) ld a5,-24...
.file "Main.c" .option pic .text .align 1 .globl createArray .type createArray, @function createArray: addi sp,sp,-32 sd ra,24(sp) sd s0,16(sp) sd s1,8(sp) mv s0,a0 mv s1,a1 slli a5,a0,32 srli a0,a5,30 call malloc@plt beq a0,zero,.L1 beq s0,zero,.L1 mv a5,a0 slli a3,s0,32 srli a4,a3,30 add a4,a4,a0...
.file "Main.c" .option pic .text .align 1 .globl createArray .type createArray, @function createArray: addi sp,sp,-32 slli a5,a0,32 sd s0,16(sp) srli s0,a5,30 sd s2,0(sp) mv s2,a0 mv a0,s0 sd s1,8(sp) sd ra,24(sp) mv s1,a1 call malloc@plt beq a0,zero,.L1 beq s2,zero,.L1 mv a5,a0 add a4,s0,a0 .L3: ...
.file "Main.c" .option pic .text .align 1 .globl createArray .type createArray, @function createArray: addi sp,sp,-32 slli a5,a0,32 sd s1,8(sp) mv s1,a0 srli a0,a5,30 sd s0,16(sp) sd ra,24(sp) mv s0,a1 call malloc@plt beq a0,zero,.L1 beq s1,zero,.L1 li a5,1 beq s1,a5,.L7 srliw a4,s1,1 slli a3,s0,32...
.arch armv8-a .file "Main.c" .text .align 2 .global createArray .type createArray, %function createArray: .LFB6: .cfi_startproc stp x29, x30, [sp, -48]! .cfi_def_cfa_offset 48 .cfi_offset 29, -48 .cfi_offset 30, -40 mov x29, sp str w0, [sp, 28] str w1, [sp, 24] ldr w0, [sp, 28] lsl x0, x0, 2 bl malloc ...
.arch armv8-a .file "Main.c" .text .align 2 .global createArray .type createArray, %function createArray: .LFB39: .cfi_startproc stp x29, x30, [sp, -32]! .cfi_def_cfa_offset 32 .cfi_offset 29, -32 .cfi_offset 30, -24 mov x29, sp stp x19, x20, [sp, 16] .cfi_offset 19, -16 .cfi_offset 20, -8 mov w19, w0 ...
.arch armv8-a .file "Main.c" .text .align 2 .p2align 4,,11 .global createArray .type createArray, %function createArray: .LFB39: .cfi_startproc stp x29, x30, [sp, -32]! .cfi_def_cfa_offset 32 .cfi_offset 29, -32 .cfi_offset 30, -24 mov x29, sp stp x19, x20, [sp, 16] .cfi_offset 19, -16 .cfi_offset 20, -...
.arch armv8-a .file "Main.c" .text .align 2 .p2align 4,,11 .global createArray .type createArray, %function createArray: .LFB39: .cfi_startproc stp x29, x30, [sp, -32]! .cfi_def_cfa_offset 32 .cfi_offset 29, -32 .cfi_offset 30, -24 mov x29, sp str x19, [sp, 16] .cfi_offset 19, -16 mov w19, w0 str d8, [...
floyd-warshall.c
#include "stdio.h" #include "stdlib.h" #include "limits.h" #define MAX_VEX_NUM 100 short int adj[MAX_VEX_NUM][MAX_VEX_NUM]; int dist[MAX_VEX_NUM][MAX_VEX_NUM]; int pred[MAX_VEX_NUM][MAX_VEX_NUM]; void floyd_warshall (int vex_num) { for (int i = 0; i < vex_num; i++) for (int j = 0; j < vex_num; j++) { ...
.file "floyd-warshall.c" .option pic .text .globl adj .bss .align 3 .type adj, @object .size adj, 20000 adj: .zero 20000 .globl dist .align 3 .type dist, @object .size dist, 40000 dist: .zero 40000 .globl pred .align 3 .type pred, @object .size pred, 40000 pred: .zero 40000 .text .align 1 .globl f...
.file "floyd-warshall.c" .option pic .text .align 1 .globl floyd_warshall .type floyd_warshall, @function floyd_warshall: ble a0,zero,.L19 addi sp,sp,-16 sd s0,8(sp) sd s1,0(sp) mv a6,a0 lla t1,adj lla t6,dist lla t5,pred addiw t0,a0,-1 slli t0,t0,32 srli t0,t0,32 li a5,200 mul t0,t0,a5 lla a5,adj+2...
.file "floyd-warshall.c" .option pic .text .align 1 .globl floyd_warshall .type floyd_warshall, @function floyd_warshall: ble a0,zero,.L20 addi sp,sp,-16 sd s0,8(sp) addiw s0,a0,-1 slli s0,s0,32 srli s0,s0,32 li t5,200 mul t5,s0,t5 lla t2,dist lla t0,pred li a7,-2147483648 lla a5,adj+200 sd s1,0(sp) ...
.file "floyd-warshall.c" .option pic .text .align 1 .globl floyd_warshall .type floyd_warshall, @function floyd_warshall: ble a0,zero,.L22 addiw t4,a0,-1 slli t4,t4,32 srli t4,t4,32 li t5,200 mul t5,t4,t5 addi sp,sp,-16 lla t2,dist lla t0,pred li a6,-2147483648 lla a5,adj+200 sd s0,8(sp) sd s1,0(sp) ...
.arch armv8-a .file "floyd-warshall.c" .text .global adj .bss .align 3 .type adj, %object .size adj, 20000 adj: .zero 20000 .global dist .align 3 .type dist, %object .size dist, 40000 dist: .zero 40000 .global pred .align 3 .type pred, %object .size pred, 40000 pred: .zero 40000 .text .align 2 .gl...
.arch armv8-a .file "floyd-warshall.c" .text .align 2 .global floyd_warshall .type floyd_warshall, %function floyd_warshall: .LFB39: .cfi_startproc mov w8, w0 cmp w0, 0 ble .L1 adrp x12, dist add x12, x12, :lo12:dist adrp x13, pred add x13, x13, :lo12:pred adrp x3, adj add x3, x3, :lo12:adj sub w0, w0,...
.arch armv8-a .file "floyd-warshall.c" .text .align 2 .p2align 4,,11 .global floyd_warshall .type floyd_warshall, %function floyd_warshall: .LFB39: .cfi_startproc mov w9, w0 cmp w0, 0 ble .L1 adrp x12, dist add x12, x12, :lo12:dist add x0, x12, 400 sub w6, w9, #1 mov w1, 400 adrp x13, pred add x13, x1...
.arch armv8-a .file "floyd-warshall.c" .text .align 2 .p2align 4,,11 .global floyd_warshall .type floyd_warshall, %function floyd_warshall: .LFB39: .cfi_startproc mov w12, w0 cmp w0, 0 ble .L1 adrp x2, .LC6 adrp x6, adj adrp x14, dist add x6, x6, :lo12:adj ldr q4, [x2, #:lo12:.LC6] adrp x2, .LC7 add x...
100_standard_init8_false-unreach-call_ground.c
extern void __VERIFIER_error() __attribute__ ((__noreturn__)); void __VERIFIER_assert(int cond) { if(!(cond)) { ERROR: __VERIFIER_error(); } } #define N 100 int main ( ) { int a [N]; int i = 0; while ( i < N ) { a[i] = 42; i = i + 1; } i = 0; while ( i < N ) { a[i] = 43; i = i + 1; } i...
.file "100_standard_init8_false-unreach-call_ground.c" .option pic .text .align 1 .globl __VERIFIER_assert .type __VERIFIER_assert, @function __VERIFIER_assert: addi sp,sp,-32 sd ra,24(sp) sd s0,16(sp) addi s0,sp,32 mv a5,a0 sw a5,-20(s0) lw a5,-20(s0) sext.w a5,a5 bne a5,zero,.L4 nop .L3: call __VERIF...
.file "100_standard_init8_false-unreach-call_ground.c" .option pic .text .align 1 .globl __VERIFIER_assert .type __VERIFIER_assert, @function __VERIFIER_assert: beq a0,zero,.L7 ret .L7: addi sp,sp,-16 sd ra,8(sp) .L3: call __VERIFIER_error@plt .size __VERIFIER_assert, .-__VERIFIER_assert .align 1 .globl m...
.file "100_standard_init8_false-unreach-call_ground.c" .option pic .text .align 1 .globl __VERIFIER_assert .type __VERIFIER_assert, @function __VERIFIER_assert: beq a0,zero,.L8 ret .L8: .L3: addi sp,sp,-16 sd ra,8(sp) call __VERIFIER_error@plt .size __VERIFIER_assert, .-__VERIFIER_assert .section .text.sta...
.file "100_standard_init8_false-unreach-call_ground.c" .option pic .text .align 1 .globl __VERIFIER_assert .type __VERIFIER_assert, @function __VERIFIER_assert: beq a0,zero,.L8 ret .L8: .L3: addi sp,sp,-16 sd ra,8(sp) call __VERIFIER_error@plt .size __VERIFIER_assert, .-__VERIFIER_assert .section .text.sta...
.arch armv8-a .file "100_standard_init8_false-unreach-call_ground.c" .text .align 2 .global __VERIFIER_assert .type __VERIFIER_assert, %function __VERIFIER_assert: .LFB0: .cfi_startproc stp x29, x30, [sp, -32]! .cfi_def_cfa_offset 32 .cfi_offset 29, -32 .cfi_offset 30, -24 mov x29, sp str w0, [sp, 28] ldr...
.arch armv8-a .file "100_standard_init8_false-unreach-call_ground.c" .text .align 2 .global __VERIFIER_assert .type __VERIFIER_assert, %function __VERIFIER_assert: .LFB0: .cfi_startproc cbz w0, .L7 ret .L7: stp x29, x30, [sp, -16]! .cfi_def_cfa_offset 16 .cfi_offset 29, -16 .cfi_offset 30, -8 mov x29, sp ...
.arch armv8-a .file "100_standard_init8_false-unreach-call_ground.c" .text .align 2 .p2align 4,,11 .global __VERIFIER_assert .type __VERIFIER_assert, %function __VERIFIER_assert: .LFB0: .cfi_startproc cbz w0, .L8 ret .L8: .L3: stp x29, x30, [sp, -16]! .cfi_def_cfa_offset 16 .cfi_offset 29, -16 .cfi_offset...
.arch armv8-a .file "100_standard_init8_false-unreach-call_ground.c" .text .align 2 .p2align 4,,11 .global __VERIFIER_assert .type __VERIFIER_assert, %function __VERIFIER_assert: .LFB0: .cfi_startproc cbz w0, .L8 ret .L8: .L3: stp x29, x30, [sp, -16]! .cfi_def_cfa_offset 16 .cfi_offset 29, -16 .cfi_offset...
01_recursion-in-c-English.c
#include <stdio.h> #include <string.h> #include <math.h> #include <stdlib.h> //Complete the following function. int find_nth_term(int n, int a, int b, int c) { switch(n) { case 1: return a; case 2: return b; case 3: return c; default: return find_nth_term(n - 1, a, b...
.file "01_recursion-in-c-English.c" .option pic .text .align 1 .globl find_nth_term .type find_nth_term, @function find_nth_term: addi sp,sp,-32 sd ra,24(sp) sd s0,16(sp) addi s0,sp,32 mv a5,a0 mv a4,a3 sw a5,-20(s0) mv a5,a1 sw a5,-24(s0) mv a5,a2 sw a5,-28(s0) mv a5,a4 sw a5,-32(s0) lw a5,-20(s0) ...
.file "01_recursion-in-c-English.c" .option pic .text .align 1 .globl find_nth_term .type find_nth_term, @function find_nth_term: li a4,2 beq a0,a4,.L3 mv a5,a0 li a4,3 mv a0,a3 beq a5,a4,.L7 li a4,1 mv a0,a1 beq a5,a4,.L7 addi sp,sp,-16 sd ra,8(sp) addiw a0,a5,-1 call find_nth_term ld ra,8(sp) add...
.file "01_recursion-in-c-English.c" .option pic .text .align 1 .globl find_nth_term .type find_nth_term, @function find_nth_term: li a6,2 li a4,3 li a5,1 beq a0,a6,.L4 .L8: beq a0,a4,.L5 beq a0,a5,.L6 addiw a0,a0,-1 bne a0,a6,.L8 .L4: mv a0,a2 ret .L5: mv a0,a3 ret .L6: mv a0,a1 ret .size find_nth_...
.file "01_recursion-in-c-English.c" .option pic .text .align 1 .globl find_nth_term .type find_nth_term, @function find_nth_term: li a6,2 li a4,3 li a5,1 beq a0,a6,.L4 .L8: beq a0,a4,.L5 beq a0,a5,.L6 addiw a0,a0,-1 bne a0,a6,.L8 .L4: mv a0,a2 ret .L5: mv a0,a3 ret .L6: mv a0,a1 ret .size find_nth_...
.arch armv8-a .file "01_recursion-in-c-English.c" .text .align 2 .global find_nth_term .type find_nth_term, %function find_nth_term: .LFB6: .cfi_startproc stp x29, x30, [sp, -32]! .cfi_def_cfa_offset 32 .cfi_offset 29, -32 .cfi_offset 30, -24 mov x29, sp str w0, [sp, 28] str w1, [sp, 24] str w2, [sp, 20]...
.arch armv8-a .file "01_recursion-in-c-English.c" .text .align 2 .global find_nth_term .type find_nth_term, %function find_nth_term: .LFB51: .cfi_startproc cmp w0, 2 beq .L3 mov w4, w0 mov w0, w3 cmp w4, 3 beq .L7 mov w0, w1 cmp w4, 1 beq .L7 stp x29, x30, [sp, -16]! .cfi_def_cfa_offset 16 .cfi_offse...
.arch armv8-a .file "01_recursion-in-c-English.c" .text .align 2 .p2align 4,,11 .global find_nth_term .type find_nth_term, %function find_nth_term: .LFB51: .cfi_startproc cmp w0, 2 beq .L4 .L8: cmp w0, 3 beq .L5 cmp w0, 1 beq .L6 sub w0, w0, #1 cmp w0, 2 bne .L8 .L4: mov w0, w2 ret .p2align 2,,3 .L5...
.arch armv8-a .file "01_recursion-in-c-English.c" .text .align 2 .p2align 4,,11 .global find_nth_term .type find_nth_term, %function find_nth_term: .LFB51: .cfi_startproc cmp w0, 2 beq .L4 .L8: cmp w0, 3 beq .L5 cmp w0, 1 beq .L6 sub w0, w0, #1 cmp w0, 2 bne .L8 .L4: mov w0, w2 ret .p2align 2,,3 .L5...
PrimeNumberofSetBitsinBinaryRepresentation.c
int bitCount(int n) { int res = 0; for (; n != 0; n &= n - 1) ++res; return res; } int isPrime(int N) //only consider prime less than 32 { if (N == 2 || N == 3 || N == 5) return 1; if (N < 2 || N % 2 == 0 || N % 3 == 0 || N % 5 == 0) return 0; return 1; } int countPrimeSetBits(int L, int R) { int res = ...
.file "PrimeNumberofSetBitsinBinaryRepresentation.c" .option pic .text .align 1 .globl bitCount .type bitCount, @function bitCount: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 mv a5,a0 sw a5,-36(s0) sw zero,-20(s0) j .L2 .L3: lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) lw a5,-36(s0) addiw a5,a5,-1 sext.w...
.file "PrimeNumberofSetBitsinBinaryRepresentation.c" .option pic .text .align 1 .globl bitCount .type bitCount, @function bitCount: mv a5,a0 beq a0,zero,.L4 li a0,0 .L3: addiw a0,a0,1 addiw a4,a5,-1 and a5,a4,a5 bne a5,zero,.L3 ret .L4: ret .size bitCount, .-bitCount .align 1 .globl isPrime .type isP...
.file "PrimeNumberofSetBitsinBinaryRepresentation.c" .option pic .text .align 1 .globl bitCount .type bitCount, @function bitCount: mv a5,a0 li a0,0 beq a5,zero,.L4 .L3: addiw a4,a5,-1 and a5,a4,a5 addiw a0,a0,1 bne a5,zero,.L3 ret .L4: ret .size bitCount, .-bitCount .align 1 .globl isPrime .type isP...
.file "PrimeNumberofSetBitsinBinaryRepresentation.c" .option pic .text .align 1 .globl bitCount .type bitCount, @function bitCount: mv a5,a0 li a0,0 beq a5,zero,.L4 .L3: addiw a4,a5,-1 and a5,a4,a5 addiw a0,a0,1 bne a5,zero,.L3 ret .L4: ret .size bitCount, .-bitCount .align 1 .globl isPrime .type isP...
.arch armv8-a .file "PrimeNumberofSetBitsinBinaryRepresentation.c" .text .align 2 .global bitCount .type bitCount, %function bitCount: .LFB0: .cfi_startproc sub sp, sp, #32 .cfi_def_cfa_offset 32 str w0, [sp, 12] str wzr, [sp, 28] b .L2 .L3: ldr w0, [sp, 28] add w0, w0, 1 str w0, [sp, 28] ldr w0, [sp, 1...
.arch armv8-a .file "PrimeNumberofSetBitsinBinaryRepresentation.c" .text .align 2 .global bitCount .type bitCount, %function bitCount: .LFB0: .cfi_startproc cbz w0, .L4 mov w1, w0 .L3: sub w2, w1, #1 ands w1, w1, w2 bne .L3 fmov s0, w0 cnt v0.8b, v0.8b addv b0, v0.8b .L1: fmov w0, s0 ret .L4: fmov s0,...
.arch armv8-a .file "PrimeNumberofSetBitsinBinaryRepresentation.c" .text .align 2 .p2align 4,,11 .global bitCount .type bitCount, %function bitCount: .LFB0: .cfi_startproc fmov s0, w0 cnt v0.8b, v0.8b addv b0, v0.8b fmov w0, s0 ret .cfi_endproc .LFE0: .size bitCount, .-bitCount .align 2 .p2align 4,,11 ...
.arch armv8-a .file "PrimeNumberofSetBitsinBinaryRepresentation.c" .text .align 2 .p2align 4,,11 .global bitCount .type bitCount, %function bitCount: .LFB0: .cfi_startproc fmov s0, w0 cnt v0.8b, v0.8b addv b0, v0.8b fmov w0, s0 ret .cfi_endproc .LFE0: .size bitCount, .-bitCount .align 2 .p2align 4,,11 ...
struct.c
#include <stdio.h> #include <string.h> struct student { char name[30]; short age; float grade; }; int main() { int i; struct student st1; struct student st2={"First",20,4.5}; st1.age=19; st1.grade=4; st2.age++; strcpy(st1.name, "Second"); }
.file "struct.c" .option pic .text .section .rodata .align 3 .LC0: .string "First" .zero 24 .half 20 .word 1083179008 .text .align 1 .globl main .type main, @function main: addi sp,sp,-112 sd ra,104(sp) sd s0,96(sp) addi s0,sp,112 la a5,__stack_chk_guard ld a4, 0(a5) sd a4, -24(s0) li a4, 0 lla a5...
.file "struct.c" .option pic .text .align 1 .globl main .type main, @function main: li a0,0 ret .size main, .-main .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.file "struct.c" .option pic .text .section .text.startup,"ax",@progbits .align 1 .globl main .type main, @function main: li a0,0 ret .size main, .-main .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.file "struct.c" .option pic .text .section .text.startup,"ax",@progbits .align 1 .globl main .type main, @function main: li a0,0 ret .size main, .-main .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.arch armv8-a .file "struct.c" .text .section .rodata .align 3 .LC1: .string "Second" .text .align 2 .global main .type main, %function main: .LFB0: .cfi_startproc stp x29, x30, [sp, -112]! .cfi_def_cfa_offset 112 .cfi_offset 29, -112 .cfi_offset 30, -104 mov x29, sp adrp x0, :got:__stack_chk_guard ld...
.arch armv8-a .file "struct.c" .text .align 2 .global main .type main, %function main: .LFB35: .cfi_startproc mov w0, 0 ret .cfi_endproc .LFE35: .size main, .-main .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.arch armv8-a .file "struct.c" .text .section .text.startup,"ax",@progbits .align 2 .p2align 4,,11 .global main .type main, %function main: .LFB35: .cfi_startproc mov w0, 0 ret .cfi_endproc .LFE35: .size main, .-main .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbit...
.arch armv8-a .file "struct.c" .text .section .text.startup,"ax",@progbits .align 2 .p2align 4,,11 .global main .type main, %function main: .LFB35: .cfi_startproc mov w0, 0 ret .cfi_endproc .LFE35: .size main, .-main .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbit...
d_mayer_fft.c
/* ** FFT and FHT routines ** Copyright 1988, 1993; Ron Mayer ** ** mayer_fht(fz,n); ** Does a hartley transform of "n" points in the array "fz". ** mayer_fft(n,real,imag) ** Does a fourier transform of "n" points of the "real" and ** "imag" arrays. ** mayer_ifft(n,real,imag) ** Does an invers...
.file "d_mayer_fft.c" .option pic .text .data .align 3 .type halsec, @object .size halsec, 80 halsec: .word 0 .word 0 .word 1057655764 .word 1057128951 .word 1057005197 .word 1056974725 .word 1056967135 .word 1056965240 .word 1056964766 .word 1056964647 .word 1056964618 .word 1056964610 .word 105696...
.file "d_mayer_fft.c" .option pic .text .align 1 .globl mayer_fht .type mayer_fht, @function mayer_fht: addi sp,sp,-96 sd s0,88(sp) sd s1,80(sp) sd s2,72(sp) sd s3,64(sp) sd s4,56(sp) sd s5,48(sp) sd s6,40(sp) sd s7,32(sp) sd s8,24(sp) sd s9,16(sp) sd s10,8(sp) sd s11,0(sp) mv s5,a0 mv s6,a1 li a5...
.file "d_mayer_fft.c" .option pic .text .align 1 .globl mayer_fht .type mayer_fht, @function mayer_fht: addi sp,sp,-112 sd s5,64(sp) sd s7,48(sp) sd s0,104(sp) sd s1,96(sp) sd s2,88(sp) sd s3,80(sp) sd s4,72(sp) sd s6,56(sp) sd s8,40(sp) sd s9,32(sp) sd s10,24(sp) sd s11,16(sp) li a5,1 mv s7,a1 mv...
.file "d_mayer_fft.c" .option pic .text .align 1 .globl mayer_fht .type mayer_fht, @function mayer_fht: addi sp,sp,-176 sd s10,80(sp) sd ra,168(sp) sd s0,160(sp) sd s1,152(sp) sd s2,144(sp) sd s3,136(sp) sd s4,128(sp) sd s5,120(sp) sd s6,112(sp) sd s7,104(sp) sd s8,96(sp) sd s9,88(sp) sd s11,72(sp) ...
.arch armv8-a .file "d_mayer_fft.c" .text .data .align 3 .type halsec, %object .size halsec, 80 halsec: .word 0 .word 0 .word 1057655764 .word 1057128951 .word 1057005197 .word 1056974725 .word 1056967135 .word 1056965240 .word 1056964766 .word 1056964647 .word 1056964618 .word 1056964610 .word 1056...
.arch armv8-a .file "d_mayer_fft.c" .text .align 2 .global mayer_fht .type mayer_fht, %function mayer_fht: .LFB0: .cfi_startproc mov x14, x0 mov w15, w1 cmp w1, 1 ble .L3 asr w3, w1, 1 sub w4, w1, #1 mov w1, w3 mov x2, 1 b .L28 .L6: cmp x2, x4 beq .L45 eor w1, w1, w3 tst w3, w1 bne .L4 mov w0, w3 ...
.arch armv8-a .file "d_mayer_fft.c" .text .align 2 .p2align 4,,11 .global mayer_fht .type mayer_fht, %function mayer_fht: .LFB0: .cfi_startproc stp x29, x30, [sp, -80]! .cfi_def_cfa_offset 80 .cfi_offset 29, -80 .cfi_offset 30, -72 mov x16, x0 mov w30, w1 mov x29, sp cmp w1, 1 ble .L3 asr w3, w1, 1 s...
.arch armv8-a .file "d_mayer_fft.c" .text .align 2 .p2align 4,,11 .global mayer_fht .type mayer_fht, %function mayer_fht: .LFB0: .cfi_startproc stp x29, x30, [sp, -144]! .cfi_def_cfa_offset 144 .cfi_offset 29, -144 .cfi_offset 30, -136 mov x29, sp stp x21, x22, [sp, 32] .cfi_offset 21, -112 .cfi_offset ...
solution.c
// https://youtu.be/krtTy-mRaNk // https://repl.it/student/assignments/484784/model_solution?fromSubmissionId=1817075 // http://www.geeksforgeeks.org/quick-sort/ #include <stdio.h> void swap(int* a, int* b) { int temp = *a; *a = *b; *b = temp; } int partition(int arr[], int low, int high) { int pivot = arr[...
.file "solution.c" .option pic .text .align 1 .globl swap .type swap, @function swap: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 sd a0,-40(s0) sd a1,-48(s0) ld a5,-40(s0) lw a5,0(a5) sw a5,-20(s0) ld a5,-48(s0) lw a4,0(a5) ld a5,-40(s0) sw a4,0(a5) ld a5,-48(s0) lw a4,-20(s0) sw a4,0(a5) nop ld s0...
.file "solution.c" .option pic .text .align 1 .globl swap .type swap, @function swap: lw a5,0(a0) lw a4,0(a1) sw a4,0(a0) sw a5,0(a1) ret .size swap, .-swap .align 1 .globl partition .type partition, @function partition: slli t1,a2,2 add t1,a0,t1 lw a7,0(t1) addiw a6,a1,-1 ble a2,a1,.L3 slli a5,a1,...
.file "solution.c" .option pic .text .align 1 .globl swap .type swap, @function swap: lw a4,0(a1) lw a5,0(a0) sw a4,0(a0) sw a5,0(a1) ret .size swap, .-swap .align 1 .globl partition .type partition, @function partition: slli t3,a2,2 add t3,a0,t3 lw t1,0(t3) mv a7,a0 addiw a6,a1,-1 ble a2,a1,.L7 s...
.file "solution.c" .option pic .text .align 1 .globl swap .type swap, @function swap: lw a4,0(a1) lw a5,0(a0) sw a4,0(a0) sw a5,0(a1) ret .size swap, .-swap .align 1 .globl partition .type partition, @function partition: slli t3,a2,2 add t3,a0,t3 lw t1,0(t3) mv a7,a0 addiw a6,a1,-1 ble a2,a1,.L7 s...
.arch armv8-a .file "solution.c" .text .align 2 .global swap .type swap, %function swap: .LFB0: .cfi_startproc sub sp, sp, #32 .cfi_def_cfa_offset 32 str x0, [sp, 8] str x1, [sp] ldr x0, [sp, 8] ldr w0, [x0] str w0, [sp, 28] ldr x0, [sp] ldr w1, [x0] ldr x0, [sp, 8] str w1, [x0] ldr x0, [sp] ldr w1,...
.arch armv8-a .file "solution.c" .text .align 2 .global swap .type swap, %function swap: .LFB23: .cfi_startproc ldr w2, [x0] ldr w3, [x1] str w3, [x0] str w2, [x1] ret .cfi_endproc .LFE23: .size swap, .-swap .align 2 .global partition .type partition, %function partition: .LFB24: .cfi_startproc sxtw ...
.arch armv8-a .file "solution.c" .text .align 2 .p2align 4,,11 .global swap .type swap, %function swap: .LFB23: .cfi_startproc ldr w3, [x1] ldr w2, [x0] str w3, [x0] str w2, [x1] ret .cfi_endproc .LFE23: .size swap, .-swap .align 2 .p2align 4,,11 .global partition .type partition, %function partition...
.arch armv8-a .file "solution.c" .text .align 2 .p2align 4,,11 .global swap .type swap, %function swap: .LFB23: .cfi_startproc ldr w3, [x1] ldr w2, [x0] str w3, [x0] str w2, [x1] ret .cfi_endproc .LFE23: .size swap, .-swap .align 2 .p2align 4,,11 .global partition .type partition, %function partition...
morse.c
/* $OpenBSD: morse.c,v 1.22 2016/03/07 12:07:56 mestre Exp $ */ /* * Copyright (c) 1988, 1993 * The Regents of the University of California. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met:...
.file "morse.c" .option pic .text .section .rodata .align 3 .LC0: .string "-----" .align 3 .LC1: .string ".----" .align 3 .LC2: .string "..---" .align 3 .LC3: .string "...--" .align 3 .LC4: .string "....-" .align 3 .LC5: .string "....." .align 3 .LC6: .string "-...." .align 3 .LC7: .string "--..." ...
.file "morse.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string " %s " .text .align 1 .globl decode .type decode, @function decode: addi sp,sp,-48 sd ra,40(sp) sd s0,32(sp) sd s1,24(sp) sd s2,16(sp) sd s3,8(sp) mv s2,a0 lla s1,.LANCHOR0 li s0,0 li s3,10 .L4: mv a1...
.file "morse.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "-----" .align 3 .LC1: .string ".-" .align 3 .LC2: .string " %s " .text .align 1 .globl decode .type decode, @function decode: addi sp,sp,-48 sd s0,32(sp) sd s1,24(sp) sd s2,16(sp) sd s3,8(sp) mv s1,a0...
.file "morse.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string " %s" .align 3 .LC1: .string "dit" .align 3 .LC2: .string "daw" .align 3 .LC3: .string "" .text .align 1 .globl morse .type morse, @function morse: addi sp,sp,-48 sd s0,32(sp) sd ra,40(sp) mv s0,a0 sd...
.arch armv8-a .file "morse.c" .text .section .rodata .align 3 .LC0: .string "-----" .align 3 .LC1: .string ".----" .align 3 .LC2: .string "..---" .align 3 .LC3: .string "...--" .align 3 .LC4: .string "....-" .align 3 .LC5: .string "....." .align 3 .LC6: .string "-...." .align 3 .LC7: .string "--..."...
.arch armv8-a .file "morse.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string " %s " .text .align 2 .global decode .type decode, %function decode: .LFB67: .cfi_startproc stp x29, x30, [sp, -48]! .cfi_def_cfa_offset 48 .cfi_offset 29, -48 .cfi_offset 30, -40 mov x29, sp stp x19, x...
.arch armv8-a .file "morse.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "-----" .align 3 .LC1: .string ".-" .align 3 .LC2: .string " %s " .text .align 2 .p2align 4,,11 .global decode .type decode, %function decode: .LFB67: .cfi_startproc stp x29, x30, [sp, -48]! .cfi_def_c...
.arch armv8-a .file "morse.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string " %s" .align 3 .LC1: .string "dit" .align 3 .LC2: .string "daw" .align 3 .LC3: .string "" .text .align 2 .p2align 4,,11 .global morse .type morse, %function morse: .LFB66: .cfi_startproc stp x29, x30,...
memcpy.c
#if __ARMEB__ || __thumb__ #include "../memcpy.c" #endif
.file "memcpy.c" .option pic .text .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.file "memcpy.c" .option pic .text .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.file "memcpy.c" .option pic .text .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.file "memcpy.c" .option pic .text .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.arch armv8-a .file "memcpy.c" .text .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.arch armv8-a .file "memcpy.c" .text .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.arch armv8-a .file "memcpy.c" .text .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
.arch armv8-a .file "memcpy.c" .text .ident "GCC: (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0" .section .note.GNU-stack,"",@progbits
client.c
#define _GNU_SOURCE #include <stdio.h> #include <fcntl.h> #include <pthread.h> #include <stdlib.h> #include <string.h> #include <sys/stat.h> #include <sys/types.h> #include <unistd.h> #include <mqueue.h> #define QUEUE_NAME "/test_queue" #define MAX_SIZE 1024 #define MSG_STOP "exit" mqd_t mq; void cleanup(voi...
.file "client.c" .option pic .text .globl mq .bss .align 2 .type mq, @object .size mq, 4 mq: .zero 4 .section .rodata .align 3 .LC0: .string "Exiting" .text .align 1 .globl cleanup .type cleanup, @function cleanup: addi sp,sp,-16 sd ra,8(sp) sd s0,0(sp) addi s0,sp,16 lla a5,mq lw a5,0(a5) mv a0,a...
.file "client.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "Exiting" .text .align 1 .globl cleanup .type cleanup, @function cleanup: addi sp,sp,-16 sd ra,8(sp) lw a0,.LANCHOR0 call mq_close@plt lla a1,.LC0 li a0,1 call __printf_chk@plt ld ra,8(sp) addi sp,sp,1...
.file "client.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "Exiting" .text .align 1 .globl cleanup .type cleanup, @function cleanup: addi sp,sp,-16 lw a0,.LANCHOR0 sd ra,8(sp) call mq_close@plt ld ra,8(sp) lla a1,.LC0 li a0,1 addi sp,sp,16 tail __printf_chk@pl...
.file "client.c" .option pic .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "Exiting" .text .align 1 .globl cleanup .type cleanup, @function cleanup: addi sp,sp,-16 lw a0,.LANCHOR0 sd ra,8(sp) call mq_close@plt ld ra,8(sp) lla a1,.LC0 li a0,1 addi sp,sp,16 tail __printf_chk@pl...
.arch armv8-a .file "client.c" .text .global mq .bss .align 2 .type mq, %object .size mq, 4 mq: .zero 4 .section .rodata .align 3 .LC0: .string "Exiting" .text .align 2 .global cleanup .type cleanup, %function cleanup: .LFB6: .cfi_startproc stp x29, x30, [sp, -16]! .cfi_def_cfa_offset 16 .cfi_offset...
.arch armv8-a .file "client.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "Exiting" .text .align 2 .global cleanup .type cleanup, %function cleanup: .LFB78: .cfi_startproc stp x29, x30, [sp, -16]! .cfi_def_cfa_offset 16 .cfi_offset 29, -16 .cfi_offset 30, -8 mov x29, sp adrp...
.arch armv8-a .file "client.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "Exiting" .text .align 2 .p2align 4,,11 .global cleanup .type cleanup, %function cleanup: .LFB78: .cfi_startproc stp x29, x30, [sp, -16]! .cfi_def_cfa_offset 16 .cfi_offset 29, -16 .cfi_offset 30, -8 a...
.arch armv8-a .file "client.c" .text .section .rodata.str1.8,"aMS",@progbits,1 .align 3 .LC0: .string "Exiting" .text .align 2 .p2align 4,,11 .global cleanup .type cleanup, %function cleanup: .LFB78: .cfi_startproc stp x29, x30, [sp, -16]! .cfi_def_cfa_offset 16 .cfi_offset 29, -16 .cfi_offset 30, -8 a...
rename.c
int rename(from, to) char *from, *to; { (void) unlink(to); if (link(from, to) < 0) return -1; (void) unlink(from); return 0; }
.file "rename.c" .option pic .text .align 1 .globl rename .type rename, @function rename: addi sp,sp,-32 sd ra,24(sp) sd s0,16(sp) addi s0,sp,32 sd a0,-24(s0) sd a1,-32(s0) ld a0,-32(s0) call unlink@plt ld a1,-32(s0) ld a0,-24(s0) call link@plt mv a5,a0 bge a5,zero,.L2 li a5,-1 j .L3 .L2: ld a0,-2...
.file "rename.c" .option pic .text .align 1 .globl rename .type rename, @function rename: addi sp,sp,-32 sd ra,24(sp) sd s0,16(sp) sd s1,8(sp) mv s1,a0 mv s0,a1 mv a0,a1 call unlink@plt mv a1,s0 mv a0,s1 call link@plt blt a0,zero,.L3 mv a0,s1 call unlink@plt li a0,0 .L2: ld ra,24(sp) ld s0,16(sp)...
.file "rename.c" .option pic .text .align 1 .globl rename .type rename, @function rename: addi sp,sp,-32 sd s1,8(sp) mv s1,a0 mv a0,a1 sd s0,16(sp) sd ra,24(sp) mv s0,a1 call unlink@plt mv a1,s0 mv a0,s1 call link@plt blt a0,zero,.L3 mv a0,s1 call unlink@plt li a0,0 .L2: ld ra,24(sp) ld s0,16(sp)...
.file "rename.c" .option pic .text .align 1 .globl rename .type rename, @function rename: addi sp,sp,-32 sd s1,8(sp) mv s1,a0 mv a0,a1 sd s0,16(sp) sd ra,24(sp) mv s0,a1 call unlink@plt mv a1,s0 mv a0,s1 call link@plt blt a0,zero,.L3 mv a0,s1 call unlink@plt li a0,0 .L2: ld ra,24(sp) ld s0,16(sp)...
.arch armv8-a .file "rename.c" .text .align 2 .global rename .type rename, %function rename: .LFB0: .cfi_startproc stp x29, x30, [sp, -32]! .cfi_def_cfa_offset 32 .cfi_offset 29, -32 .cfi_offset 30, -24 mov x29, sp str x0, [sp, 24] str x1, [sp, 16] ldr x0, [sp, 16] bl unlink ldr x1, [sp, 16] ldr x0, [...
.arch armv8-a .file "rename.c" .text .align 2 .global rename .type rename, %function rename: .LFB0: .cfi_startproc stp x29, x30, [sp, -32]! .cfi_def_cfa_offset 32 .cfi_offset 29, -32 .cfi_offset 30, -24 mov x29, sp stp x19, x20, [sp, 16] .cfi_offset 19, -16 .cfi_offset 20, -8 mov x20, x0 mov x19, x1 m...
.arch armv8-a .file "rename.c" .text .align 2 .p2align 4,,11 .global rename .type rename, %function rename: .LFB0: .cfi_startproc stp x29, x30, [sp, -32]! .cfi_def_cfa_offset 32 .cfi_offset 29, -32 .cfi_offset 30, -24 mov x29, sp stp x19, x20, [sp, 16] .cfi_offset 19, -16 .cfi_offset 20, -8 mov x19, x1...
.arch armv8-a .file "rename.c" .text .align 2 .p2align 4,,11 .global rename .type rename, %function rename: .LFB0: .cfi_startproc stp x29, x30, [sp, -32]! .cfi_def_cfa_offset 32 .cfi_offset 29, -32 .cfi_offset 30, -24 mov x29, sp stp x19, x20, [sp, 16] .cfi_offset 19, -16 .cfi_offset 20, -8 mov x19, x1...