|
From: | Waksmanski, Lukasz |
Subject: | [qemu-hexagon] Error mapping file: Invalid argument |
Date: | Mon, 13 Sep 2021 18:38:39 +0000 |
Hello, I’m trying to run Hexagon executables in qemu-hexagon. I’m using official stable version v6.1. Here’s my rather simple program: ➜ ~ cat test.c #include<stdio.h> int main() { printf("Hello Hexagon!"); return 0; } I’m using Hexagon SDK 4.0.2 toolchain: ➜ ~ ~/tools/Hexagon4/tools/HEXAGON_Tools/8.4.09/Tools/bin/hexagon-clang -mv67 -o test test.c Running in qemu produces error somewhere in mmap ➜ ~ qemu-hexagon ./test
qemu-hexagon: ./test: Error mapping file: Invalid argument Am I doing something naively wrong here?
Here’s are the some details about the executable ➜ ~ ~/tools/Hexagon4/tools/HEXAGON_Tools/8.4.09/Tools/bin/hexagon-llvm-readelf -h ./test
ELF Header: Magic: 7f 45 4c 46 01 01 01 00 00 00 00 00 00 00 00 00 Class: ELF32 Data: 2's complement, little endian Version: 1 (current) OS/ABI: UNIX - System V ABI Version: 0x0 Type: EXEC (Executable file) Machine: Qualcomm Hexagon Version: 0x1 Entry point address: 0x0 Start of program headers: 52 (bytes into file) Start of section headers: 78848 (bytes into file) Flags: 0x67, V67 Size of this header: 52 (bytes) Size of program headers: 32 (bytes) Number of program headers: 3 Size of section headers: 40 (bytes) Number of section headers: 16 Section header string table index: 13 Section Headers: [Nr] Name Type Address Off Size ES Flg Lk Inf Al [ 0] NULL 00000000 000000 000000 00 0 0 0 [ 1] .start PROGBITS 00000000 001000 004680 00 WAX 0 0 64 [ 2] .init PROGBITS 00005000 006000 000064 00 AX 0 0 32 [ 3] .text PROGBITS 00006000 007000 005a88 00 AX 0 0 4096 [ 4] .fini PROGBITS 0000baa0 00caa0 000030 00 AX 0 0 32 [ 5] .rodata PROGBITS 0000bad0 00cad0 000678 00 A 0 0 8 [ 6] .eh_frame PROGBITS 0000c160 00d160 000004 00 A 0 0 32 [ 7] .data PROGBITS 0000d000 00e000 000708 00 WA 0 0 8 [ 8] .ctors PROGBITS 0000d708 00e708 000010 00 WA 0 0 4 [ 9] .dtors PROGBITS 0000d718 00e718 000014 00 WA 0 0 4 [10] .sdata PROGBITS 0000e000 00f000 0000a8 00 WAp 0 0 4096 [11] .bss NOBITS 0000e0a8 00f0a8 000e5c 00 WA 0 0 8 [12] .comment PROGBITS 00000000 00f0a8 0000d4 00 MS 0 0 1 [13] .shstrtab STRTAB 00000000 00f17c 00006f 00 0 0 1 [14] .symtab SYMTAB 00000000 00f1ec 0024e0 10 15 248 4 [15] .strtab STRTAB 00000000 0116cc 001d19 00 0 0 1 Could you tell me where the problem is?
Is it because I’m compiling for QuRT, and qemu uses is linux-user? Or is something else? Best regards, Łukasz Waksmański M +48 668 282 017 www.dolby.com
|
Lukasz.Waksmanski@dolby.com |
[Prev in Thread] | Current Thread | [Next in Thread] |