Open JKBert opened 3 years ago
Some news.
I remember I have used uECC without this kind of bug. I have rebuilt the same code (with uECC_avr defined), but I have compiled this library not with gcc 11.1.0, but with 5.4.0.
And I obtain :
Loaded 18710 .text at address 0x0
Loaded 416 .data
Init...
Init alea...
Init random_ecc...
93A980352F127448C19FB0213622B13D5FEFC07CA4E6EA3A22234E7F0D9634FF8F2854B25A6E70F9E2063AB47040A341B54D39FD4845FB6D86CA33C8CFB5E308...
93A980352F127448C19FB0213622B13D5FEFC07CA4E6EA3A22234E7F0D9634FF8F2854B25A6E70F9E2063AB47040A341B54D39FD4845FB6D86CA33C8CFB5E308...
Done...
Now the question ;-) Did I find a bug or does gcc 11 need a special build option to compile uECC ?
Hello, I'm using this library on an ATmega 1284 CPU and it only runs as expected if I define uECC_arch_other. When library is built with uECC_avr, all tests fail.
For example, I have written this simple test:
Build options are: -mmcu=atmega1284 -O2 with avr-gcc 11.1.0.
With uECC_PLATFORM set to uECC_avr, my test returns:
With uECC_PLATFORM set to uECC_arch_other (thus, without assembly optimization):
I have checked return of asmb subroutines and they return faulty values. I suppose I have done a mistake in compilation stage but I'm unable to find my mistake.
Best regards,
JB