GCC

  • 1 Replies
  • 284 Views
*

Offline philmoz

  • *****
  • 3070
    • Photos
GCC
« on: 30 / June / 2017, 23:14:09 »
Advertisements
  In case anyone want to try it, I've added support for building with ARM GCC v5 to the 1.5 trunk.


Currently there is one issue where functions/variables only referenced in inline assembly code may get optimised out of the C code (e.g. S80 won't build).
Other than that 5.4 seems to work ok on my cameras, can't see any major improvements for CHDK though.


Phil.

« Last Edit: 30 / June / 2017, 23:17:12 by philmoz »
CHDK ports:
  sx30is (1.00c, 1.00h, 1.00l, 1.00n & 1.00p)
  g12 (1.00c, 1.00e, 1.00f & 1.00g)
  sx130is (1.01d & 1.01f)
  ixus310hs (1.00a & 1.01a)
  sx40hs (1.00d, 1.00g & 1.00i)
  g1x (1.00e, 1.00f & 1.00g)

*

Offline philmoz

  • *****
  • 3070
    • Photos
Re: GCC
« Reply #1 on: 20 / October / 2017, 21:04:23 »
Word of caution - I tried building with GCC6 and it currently breaks CHDK.


Although it builds, the result won't run.
It seems that GCC6 generates 'LDR PC, LR' instructions as function exit instead of 'BX LR'.
This crashes if returning to a Thumb function from and ARM function.


There may be option(s) to fix this; but a quick search did not find anything obvious.


Phil.

CHDK ports:
  sx30is (1.00c, 1.00h, 1.00l, 1.00n & 1.00p)
  g12 (1.00c, 1.00e, 1.00f & 1.00g)
  sx130is (1.01d & 1.01f)
  ixus310hs (1.00a & 1.01a)
  sx40hs (1.00d, 1.00g & 1.00i)
  g1x (1.00e, 1.00f & 1.00g)