On 9/6/2022 12:22 AM, Philipp Klaus Krause wrote:
> Am 05.09.22 um 19:32 schrieb Don Y:
>>
>> I've rarely worried about code *size* and only seldom worried about
>> efficiency (execution speed).
>>
>> But, I *do* get annoyed if the generated code doesn't do what it
>> was supposed to do! Or, does it with unexpected side-effects, etc.
>
> However, the replies so far show that code size, not wrong code is the problem.
Understood. I was merely relaying my experiences (e.g., abandoning MS
because of their approach to bug fixes). Most of my "smaller" projects
have had large codebases (it wasn't uncommon to have a 250KB binary running
on an 8b MCU; sewing various "bank switching" schemes into the toolkit
was a prerequisite)
> IMO, that is not surprising for mcs51: The mcs51 port in SDCC is old, bug
> reports come in rarely, and in recnet years, most work on mcs51 has been
> bugfixes. IMO, the mcs51 port is very stable. Improving code generation always
> comes with the risk of introducing bugs. Still, if time allows, it might be
> worth it (and I hope that most of the new bugs will be found before a release).
>
>> To that end, the biggest win was vendor responsiveness; knowing
>> that reporting a bug will result in prompt attention to fix *that*
>> bug […]
>>
>> Unfortunately (for you, supporting a product), the only way to get that
>> sort of responsiveness is to make "support" your full-time job. <frown>
>
> Unpaid support with fixed response times for a free compiler doesn't look like
> a good full-time job to me.
Exactly. FOSS projects that thrive seem to rely on lots of eyes and hands
so the "load" isn't too great on any one individual. But, many projects
are relatively easy to contribute without requiring specific knowledge
beyond "this code fragment looks broken". E.g., I have no problem commiting
patches for drivers and many services -- but don't bother doing so with gcc
as the "admission fee" is too high.
> IMO, in general, the SDCC support channels (ticket
> trackers, mailing lists) are quite responsive; most of the time, there is a
> reply within hours, but sometimes it takes much longer.
My experience with tools for small processors predates "internet forums".
I would typically have had to log on (with a modem) to a vendor's "BBS"
and leave a message, there; picking up a new binary (from there) when
available and transfering it via X/Y/ZMODEM to my own host.
One typically didn't see other correspondence from other customers.
Nor do I imagine they saw my bug reports or the vendors' announcements
of new binaries built in response to those (unless the vendor deliberately
reached out to them).
>>> In my opinion, the best way forward from here to make SDCC more competitive
>>> vs. non-free compilers is:
>>>
>>> 0) Improve machine-independent optimizations
>>> 1) Improve machine-dependent optimizations for mcs51
>>> 2) Improve debug support and integration
>>> 3) Find and fix bugs
>>
>> If "uptake" is your goal, you might focus on just a single processor (8051
>> family seems a common application) and be known for how well you address
>> *that* segment of the market -- rather than trying to bring the quality
>> of all code generators up simultaneously.
>
> Well, I asked for reasons why people are using non-free compilers instead of
> SDCC. Many of the replies were indeed for mcs51. IMO, this is because the mcs51
> is a common µC where SDCC has fallen behind vs. the non-free compilers.
It could also be that many of the 8b devices are just not seeing much
market share (or have fallen out of production). How many 68xx devices
win designs nowadays? Does Zilog even make processors anymore? Etc.
Other "small CPU" vendors often offer their own toolchains thus removing the
burden of that expense (free competing with free).
OTOH, the '51 (et al.) is a pretty ubiquitous architecture offered by
a variety of vendors. And, at relatively high levels of integration
(compared to 8b processors of days gone by)
> SDCC has other ports, that got far less replies, because the architectures are
> less common (e.g. ds390) or because SDCC is already the leading compiler for
> them (e.g. stm8).
> 0)-3) were chosen is a way that I hope will make SDCC more competitive for
> mcs51, while not neglecting other ports.
Again, good luck!