12 May 2017, 01:54 | #261 |
AmigaDev.com
Join Date: Mar 2016
Location: Stockholm, Sweden
Age: 35
Posts: 625
|
Managed to get it to compile and link properly with -noixemul, but trying to launch the binary in UAE results in a lockup. I'm not sure how to debug stuff like that. Any tips?
IT RUNS! EDIT: However, there needs to be some tweaking before it's actually usable.
Last edited by Marlon_; 12 May 2017 at 02:22. |
12 May 2017, 09:23 | #262 | |
bye
Join Date: Jun 2016
Location: Some / Where
Posts: 681
|
Quote:
Code:
friend class PPSingleton<ClipBoard>; }; friend class PPSingleton<EnvelopeEditor::ClipBoard>; // add this line |
|
12 May 2017, 11:55 | #263 | |
AmigaDev.com
Join Date: Mar 2016
Location: Stockholm, Sweden
Age: 35
Posts: 625
|
Quote:
Code:
template<> EnvelopeEditor::ClipBoard * PPSingleton<EnvelopeEditor::ClipBoard>::instance = NULL; Since I got it to compile and run either way, and there's a lot of tweaks needed, I'll probably go back and change this. Thank you for the help! =) |
|
12 May 2017, 13:29 | #264 | |
bye
Join Date: Jun 2016
Location: Some / Where
Posts: 681
|
Quote:
|
|
12 May 2017, 13:46 | #265 |
AmigaDev.com
Join Date: Mar 2016
Location: Stockholm, Sweden
Age: 35
Posts: 625
|
I'll probably do that. But I think the proper way to go is to do a fork of the official repo and apply my fixes there.
|
13 May 2017, 10:23 | #266 |
Registered User
Join Date: Dec 2010
Location: Athens/Greece
Age: 53
Posts: 725
|
Build stops on 'configure' libnix.
System: mint (ubuntu based) 64bit Code:
DEBUG: enter directory ".build-m68k/build/libnix" DEBUG: execute "/home/alex/amiga/amigaos-cross-toolchain/submodules/libnix/configure --prefix=/home/alex/amiga/gcc6/m68k-amigaos/libnix --host=i686-linux-gnu --target=m68k-amigaos" creating cache ./config.cache checking for gcc... m68k-amigaos-gcc checking whether the C compiler (m68k-amigaos-gcc ) works... no configure: error: installation or configuration problem: C compiler cannot create executables. ERROR: command "/home/alex/amiga/amigaos-cross-toolchain/submodules/libnix/configure --prefix=/home/alex/amiga/gcc6/m68k-amigaos/libnix --host=i686-linux-gnu --target=m68k-amigaos" failed with 1 Code:
cat .build-m68k/build/libnix/config.log This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. configure:529: checking for gcc configure:642: checking whether the C compiler (m68k-amigaos-gcc ) works configure:658: m68k-amigaos-gcc -o conftest conftest.c 1>&5 configure:655:1: warning: return type defaults to 'int' [-Wimplicit-int] /home/alex/amiga/gcc6/lib/gcc/m68k-amigaos/6.3.1d/../../../../m68k-amigaos/bin/ld: cannot find -lgcc collect2: error: ld returned 1 exit status configure: failed program was: #line 653 "configure" #include "confdefs.h" main(){return(0);} Code:
./toolchain-m68k --prefix=/home/alex/amiga/gcc6 --m32 build |
13 May 2017, 12:37 | #267 |
bye
Join Date: Jun 2016
Location: Some / Where
Posts: 681
|
OK. I changed the build order: libgcc is now built before libnix.
|
13 May 2017, 19:31 | #268 |
Registered User
Join Date: Dec 2010
Location: Athens/Greece
Age: 53
Posts: 725
|
It builds correctly now. Thanks!
|
14 May 2017, 06:45 | #269 |
Registered User
Join Date: Dec 2010
Location: Athens/Greece
Age: 53
Posts: 725
|
Is the standard c++ hello world supposed to compile and work?
...or are c++ streams currently not supported? Code:
#include <iostream> int main(int argc, char *argv[]) { std::cout << "Hello world\n"; return 0; } |
14 May 2017, 07:47 | #270 |
Total Chaos forever!
Join Date: Aug 2007
Location: Waterville, MN, USA
Age: 49
Posts: 2,200
|
LibStdC++ isn't done yet, AFAIK.
|
14 May 2017, 12:34 | #271 |
WinUAE developer
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,574
|
Not really 6.2 specific but if this becomes AROS m68k compiler some day.. (Hopefully soon enough)
6.3 (probably earlier 6.x version too) seems to have a bug, at least in 68000 mode: Source (AROS poseidon.library.c) Code:
/* /// "psdGetAttrsA()" */ AROS_LH3(LONG, psdGetAttrsA, AROS_LHA(ULONG, type, D0), AROS_LHA(APTR, psdstruct, A0), AROS_LHA(struct TagItem *, tags, A1), LIBBASETYPEPTR, ps, 22, psd) { AROS_LIBFUNC_INIT struct TagItem *ti; ULONG count = 0; ULONG *packtab = NULL; KPRINTF(1, ("psdGetAttrsA(%ld, %p, %p)\n", type, psdstruct, tags)); if(type <= PGA_LAST) { packtab = (ULONG *) PsdPTArray[type]; } <snip> Code:
4792899C 48e7 3832 MOVEM.L D2-D4/A2-A3/A6,-(A7) 479289A0 2608 MOVE.L A0,D3 479289A2 2449 MOVEA.L A1,A2 479289A4 264e MOVEA.L A6,A3 ; Right shift by 4? D0=1 (PGA_STACK) becomes zero.. ; I guess this is optimized "if(type <= PGA_LAST)" test (PGA_LAST = 15) so shift by 4 becomes zero if <=15. 479289A6 e888 LSR.L #$00000004,D0 479289A8 6600 023a BNE.W #$023a == $47928be4 ; this move should have been before above LSR.L.. ; D0 is now always zero 479289AC 2200 MOVE.L D0,D1 ; *4 479289AE d280 ADD.L D0,D1 479289B0 d281 ADD.L D1,D1 ; packtab = (ULONG *) PsdPTArray[type]; 479289B2 41f9 4793 41dc LEA.L $479341dc,A0 479289B8 2830 1800 MOVE.L (A0, D1.L*1, $00),D4 <snip> |
14 May 2017, 20:55 | #272 |
Registered User
Join Date: Aug 2016
Location: germany
Posts: 67
|
have encountered a new problem
what shall i do here? (to send a bug-report to the gnu-developers wont be the right way, will it be?) Code:
MAININTRO.c: In function ‘GREATEFFECT’: MAININTRO.c:426:1: error: unrecognizable insn: } ^ (insn 2323 2326 1228 (set (strict_low_part (reg:QI 0 d0 [orig:778 AScr ] [778])) (mem (reg:SI 10 a2) [0 S0])) -1 (nil)) MAININTRO.c:426:1: internal compiler error: in extract_insn, at recog.c:2287 0x87cc5ec _fatal_insn(char const*, rtx_def const*, char const*, int, char const*) /home/renef/AMIGA/new/amigaos-cross-toolchain/submodules/gcc-6/gcc/rtl-error.c:108 0x87cc615 _fatal_insn_not_found(rtx_def const*, char const*, int, char const*) /home/renef/AMIGA/new/amigaos-cross-toolchain/submodules/gcc-6/gcc/rtl-error.c:116 0x878a4cf extract_insn(rtx_insn*) /home/renef/AMIGA/new/amigaos-cross-toolchain/submodules/gcc-6/gcc/recog.c:2287 0x878a1d1 extract_insn_cached(rtx_insn*) /home/renef/AMIGA/new/amigaos-cross-toolchain/submodules/gcc-6/gcc/recog.c:2178 0x852b169 cleanup_subreg_operands(rtx_insn*) /home/renef/AMIGA/new/amigaos-cross-toolchain/submodules/gcc-6/gcc/final.c:3106 0x852abd4 final_scan_insn(rtx_insn*, _IO_FILE*, int, int, int*) /home/renef/AMIGA/new/amigaos-cross-toolchain/submodules/gcc-6/gcc/final.c:2907 0x852928f final(rtx_insn*, _IO_FILE*, int) /home/renef/AMIGA/new/amigaos-cross-toolchain/submodules/gcc-6/gcc/final.c:2045 0x852d3ce rest_of_handle_final /home/renef/AMIGA/new/amigaos-cross-toolchain/submodules/gcc-6/gcc/final.c:4448 0x852d5a4 execute /home/renef/AMIGA/new/amigaos-cross-toolchain/submodules/gcc-6/gcc/final.c:4523 Please submit a full bug report, with preprocessed source if appropriate. Please include the complete backtrace with any bug report. See <http://gcc.gnu.org/bugs.html> for instructions. |
14 May 2017, 21:13 | #273 |
bye
Join Date: Jun 2016
Location: Some / Where
Posts: 681
|
Best way is:
1. Create a ticket at https://github.com/bebbo/amigaos-cross-toolchain/issues 2. If you wanna support me more: test if it's one of my optimizers and maybe which one, by compiling/testing with a) bebbo's optimizers disabled: -fbbb=- b) watch which optimizers are used: -fbbb=+v c) test with specific optimizers enabled: -fbbb=aspcemrfbv (test each single letter or combinations of letters) An example is https://github.com/bebbo/amigaos-cro...hain/issues/19 |
14 May 2017, 21:25 | #274 | |
bye
Join Date: Jun 2016
Location: Some / Where
Posts: 681
|
Quote:
I built a small test case: Code:
long f(register unsigned type asm("d0")) { if(type <= PGA_LAST) { unsigned const * p = PsdPTArray[type]; return *p; } return -1; } That bug is presumably caused by the register parameter since using a stack parameter let's that weird LSR instruction vanish. Not sure if I can fix that. Last edited by bebbo; 14 May 2017 at 21:41. |
|
14 May 2017, 21:57 | #275 | |
Registered User
Join Date: Aug 2016
Location: germany
Posts: 67
|
Quote:
hope that helps you - if there is anything more i need to provide, please let me know |
|
15 May 2017, 11:55 | #276 | |
Registered User
Join Date: Aug 2007
Location: berlin/germany
Posts: 1,054
|
im trying to update to test what toni requests, but i ran into:
Quote:
|
|
15 May 2017, 13:11 | #277 |
bye
Join Date: Jun 2016
Location: Some / Where
Posts: 681
|
dang - sorry - i published a wrong commit...
... merged it back now - hope I did not mess it totally up now... /duck |
15 May 2017, 14:56 | #278 |
Registered User
Join Date: Aug 2007
Location: berlin/germany
Posts: 1,054
|
|
15 May 2017, 18:21 | #279 |
WinUAE developer
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,574
|
I forgot that -Os is AROS m68k default. -O1 just fits (only 13k free, vs -Os which leaves ~70k free), -O2 does not fit (26k too big). I haven't done any performance tests. (Note that debugging was disabled but serial logging is enabled)
-O1 does "fix" it. (test is done with normal cmp.w) |
15 May 2017, 22:56 | #280 | |
bye
Join Date: Jun 2016
Location: Some / Where
Posts: 681
|
Quote:
Maybe you can reach almost the code size of -Os by using -O1 plus disabling some of the size expensive optimizations. |
|
Currently Active Users Viewing This Thread: 2 (0 members and 2 guests) | |
Thread Tools | |
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
New GCC based dev toolchain for AmigaOS 3.x | cla | Coders. Releases | 8 | 24 December 2017 10:18 |
Issue with photon/xxxx WinUAE Toolchain | arpz | Coders. Asm / Hardware | 2 | 26 September 2015 22:33 |
New 68k gcc toolchain | arti | Coders. C/C++ | 17 | 31 July 2015 03:59 |
Hannibal's WinUAE Demo Toolchain 5 | Bobic | Amiga scene | 1 | 23 July 2015 21:04 |
From gcc to vbcc. | Cowcat | Coders. General | 9 | 06 June 2014 14:45 |
|
|