[MAGEEC] Removing dependencies from BEEBS

Jeremy Bennett jeremy.bennett at embecosm.com
Thu Oct 3 08:33:28 BST 2013


On 02/10/13 20:25, James Pallister wrote:
> Hi All,
>
> I've been working on the BEEBS benchmarks recently, and was considering
> removing dependencies on the C std library. This would involve having
> implementations of the (few) functions used in the benchmarks as part of
> those benchmarks themselves. For example, the encryption benchmarks use
> rand to create the data which is to be encrypted. The rand function
> would be incorporated as part of the benchmark.
>
> Reasons for:
>      * No external dependencies
>      * Reduced benchmark size
>      * When testing optimizations, the relevant standard library code
> will also be optimized under the same optimization level. This happened
> before with the cubic benchmark - the majority of computation is
> performed in precompiled std library functions - cos, sin, sqrt, etc.
> The result was that optimizing the cubic benchmark had little effect,
> due to the precompiled std library being linked in.
>      * The code is more independent of external factors - e.g. using
> newlib vs uClib.
>      * There isn't much code dependent on std library features (dijkstra,
> cubic)
>
> Reasons against:
>      * Possible code bloat - repetition of code between benchmarks?
>      * Repetition of code that would normally be expected to be provided
> (std lib functions such as malloc, rand)
>      * Additional complexity.
>
>
> I'm currently leaning towards making the benchmarks standalone. Any
> thoughts on whether this is a good or a bad idea?

I'm not sure this is a good idea. The C library is a standard part of 
any compiler system, and reasonably ought to be included.

Let's discuss when we meet on Wednesday.

Best wishes,


Jeremy

-- 
Tel:      +44 (1590) 610184
Cell:     +44 (7970) 676050
SkypeID: jeremybennett
Twitter: @jeremypbennett
Email:   jeremy.bennett at embecosm.com
Web:     www.embecosm.com




More information about the mageec mailing list