Skip to content

Commit d8caae3

Browse files
add regression test for float multiply bug
1 parent 274b012 commit d8caae3

File tree

3 files changed

+74
-0
lines changed

3 files changed

+74
-0
lines changed

test/regression/bug0002/autotest.json

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
{
2+
"transfer_files": [
3+
"bin/DEMO.8xp"
4+
],
5+
"target": {
6+
"name": "DEMO",
7+
"isASM": true
8+
},
9+
"sequence": [
10+
"action|launch",
11+
"delay|200",
12+
"hashWait|1",
13+
"key|enter",
14+
"delay|300",
15+
"hashWait|2"
16+
],
17+
"hashes": {
18+
"1": {
19+
"description": "Value should be 9375000",
20+
"start": "vram_start",
21+
"size": "vram_16_size",
22+
"expected_CRCs": [
23+
"B5D5ACEB"
24+
]
25+
},
26+
"2": {
27+
"description": "Exit",
28+
"start": "vram_start",
29+
"size": "vram_16_size",
30+
"expected_CRCs": [
31+
"FFAF89BA",
32+
"101734A5",
33+
"9DA19F44",
34+
"A32840C8",
35+
"349F4775"
36+
]
37+
}
38+
}
39+
}

test/regression/bug0002/makefile

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# ----------------------------
2+
# Makefile Options
3+
# ----------------------------
4+
5+
NAME = DEMO
6+
ICON = icon.png
7+
DESCRIPTION = "CE C Toolchain Demo"
8+
COMPRESSED = NO
9+
ARCHIVED = NO
10+
11+
CFLAGS = -Wall -Wextra -Oz
12+
CXXFLAGS = -Wall -Wextra -Oz
13+
14+
# ----------------------------
15+
16+
include $(shell cedev-config --makefile)

test/regression/bug0002/src/main.c

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
#include <ti/screen.h>
2+
#include <ti/getkey.h>
3+
#include <inttypes.h>
4+
#include <stdio.h>
5+
6+
int main(void)
7+
{
8+
volatile uint64_t x = 3750000;
9+
10+
os_ClrHome();
11+
12+
x *= 2.5;
13+
14+
printf("value: %llu\n", x);
15+
16+
os_GetKey();
17+
18+
return 0;
19+
}

0 commit comments

Comments
 (0)