I agree with Felix. I found libtommath issue in dropbear several
months before. I can confirm the issue fixed by upgrading libtommath
and libtomcrypt. The update is already done by upstream, but not
released yet.

You can try a CI-successfully-built commit from
https://github.com/mkj/dropbear and see if the dropbear issue still
exists.


Best Regards,
Syrone Wong


On Mon, Dec 18, 2017 at 4:40 PM, Felix Fietkau <n...@nbd.name> wrote:
> On 2017-12-17 22:21, Hauke Mehrtens wrote:
>> This patch made GCC produce broken code, remove it.
>> In mp_cmp_d() function in th libtommath shipped with dropbear the
>> following code was compiled wrong:
>>
>> /* compare based on magnitude */
>> if (a->used > 1) {
>>   return 1;
>> }
>>
>> In the broken ASM this part returned -1 like the previous return
>> statement did instead of 1 like it should.
>>
>> This did not happen when the -funroll-loops option was given to GCC.
>>
>> Signed-off-by: Hauke Mehrtens <ha...@hauke-m.de>
> This patch only passes the cost associated with branches and memory
> transfers to other parts of GCC, which causes it to generate different
> code (matching what it already does on -O2).
> I'm pretty sure that by removing the patch you're simply hiding the real
> issue which can easily creep in again in other places when compiling
> with -O2. I don't think we can trust GCC 7 on MIPS before we find and
> fix the real bug.
>
> - Felix
>
> _______________________________________________
> Lede-dev mailing list
> Lede-dev@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/lede-dev

_______________________________________________
Lede-dev mailing list
Lede-dev@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/lede-dev

Reply via email to