Sign in
gem5
/
public
/
gem5-resources
/
ce75ff570e699a1e32457ff72aeaff84a9bc6c90
/
.
/
src
/
riscv-tests
/
debug
/
programs
/
counting_loop.c
blob: 7c7d6002356e174de5bdc6a18296cd739c04e452 [
file
] [
log
] [
blame
]
#include
<stdio.h>
#include
<string.h>
#include
<stdint.h>
#include
<stdlib.h>
int
main
()
{
int
sum
=
0
;
int
counter
=
0
;
while
(
counter
<
10
)
{
counter
=
counter
+
1
;
sum
=
sum
+
counter
;
}
return
counter
;
}