public inbox for sid@sourceware.org
 help / color / mirror / Atom feed
* component_library object not found in lib
@ 2008-09-17  8:58 Aurélien Buhrig
  2008-09-17 13:45 ` Frank Ch. Eigler
  0 siblings, 1 reply; 7+ messages in thread
From: Aurélien Buhrig @ 2008-09-17  8:58 UTC (permalink / raw)
  To: sid

Hi,

I try to create some SID peripherals (timer, it crtl for now) for a new
target microcontroller called tam16 in a tam16family  library.
I added the tam16family_component_library definition in the components.cxx
file:

DLLEXPORT extern const component_library tam16family_component_library;
const component_library tam16family_component_library = {…};

I had no particular problem adding the interrupt controller. But things go
wrong  when adding a second peripheral (timer)…
At the configuration, this error occurs:

dlsym of tam16family_component_library in component library dso
libtam16family.la failed: sid: undefined symbol:
tam16family_component_library

“Stracing” the sid execution shows that sid points to the good library in
which tam16family_component_library symbol DOES exist, in both .so and .a,
only once per lib, and as a global symbol.

My system is RHEL5/x86_64, gcc 3.4.6.

Any hint why it is not found by the libltdl ?

Thanks,
Aurelien



^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: component_library object not found in lib
  2008-09-17  8:58 component_library object not found in lib Aurélien Buhrig
@ 2008-09-17 13:45 ` Frank Ch. Eigler
  2008-09-17 16:20   ` Aurélien Buhrig
  2008-10-09  9:32   ` timings in sid Aurélien Buhrig
  0 siblings, 2 replies; 7+ messages in thread
From: Frank Ch. Eigler @ 2008-09-17 13:45 UTC (permalink / raw)
  To: Aurélien Buhrig; +Cc: sid

Hi -

> DLLEXPORT extern const component_library tam16family_component_library;
> const component_library tam16family_component_library = { ... };

This looks fine.

> I had no particular problem adding the interrupt controller. But things go
> wrong when adding a second peripheral (timer).

Do you mean that the same component_library file worked when you had
only one component type supported in list_types etc., but didn't load
when more are available in the source?

> At the configuration, this error occurs: dlsym of
> tam16family_component_library in component library dso
> libtam16family.la failed: sid: undefined symbol:
> tam16family_component_library

You could try
   env LD_DEBUG=all sid ...

My guess is that there is a typo in your source code that allowed the
.so to be built with an undefined external reference.  That in turn
can cause the .so to fail to load, even if the
tam16_family_component_library symbol itself was there.

- FChE

^ permalink raw reply	[flat|nested] 7+ messages in thread

* RE: component_library object not found in lib
  2008-09-17 13:45 ` Frank Ch. Eigler
@ 2008-09-17 16:20   ` Aurélien Buhrig
  2008-10-09  9:32   ` timings in sid Aurélien Buhrig
  1 sibling, 0 replies; 7+ messages in thread
From: Aurélien Buhrig @ 2008-09-17 16:20 UTC (permalink / raw)
  To: 'Frank Ch. Eigler'; +Cc: sid

I didn't know LD_DEBUG variable... and it saved my life! Thanks!
It was a destructor that was declared but not defined... ouch!

-no-undefined was specified in LDFLAGS though...
Is it normal there were no error?

Thanks!

Aurélien


^ permalink raw reply	[flat|nested] 7+ messages in thread

* timings in sid
  2008-09-17 13:45 ` Frank Ch. Eigler
  2008-09-17 16:20   ` Aurélien Buhrig
@ 2008-10-09  9:32   ` Aurélien Buhrig
  2008-10-09 16:24     ` Dave Brolley
  1 sibling, 1 reply; 7+ messages in thread
From: Aurélien Buhrig @ 2008-10-09  9:32 UTC (permalink / raw)
  To: sid

Hello,

I try to link timer peripheral time with processor execution time.
The target processor is an asynchronous processor for which the execution
latency is not a number of cycles, but rather a number of ns. There is no
parallelism.

So I planned to use the same simulation scheduler for both timer and CPU. I
described several execution unit in the .cpu, with different timing, but it
seems the latency of the instructions has no effect on the execution
scheduler. The sched tick is incremented by 1 at each instruction regardless
of latency of the execution unit.

How can I do? Where are the timing information saved ?

Thanks,
Aurélien




^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: timings in sid
  2008-10-09  9:32   ` timings in sid Aurélien Buhrig
@ 2008-10-09 16:24     ` Dave Brolley
  2008-10-10 16:29       ` Aurélien Buhrig
  0 siblings, 1 reply; 7+ messages in thread
From: Dave Brolley @ 2008-10-09 16:24 UTC (permalink / raw)
  To: Aurélien Buhrig; +Cc: sid

Did you run sid with --final-insn-count  and/or --trace-counter and 
possibly with --insn-count=1?

I hope this helps,
Dave

Aurélien Buhrig wrote:
> Hello,
>
> I try to link timer peripheral time with processor execution time.
> The target processor is an asynchronous processor for which the execution
> latency is not a number of cycles, but rather a number of ns. There is no
> parallelism.
>
> So I planned to use the same simulation scheduler for both timer and CPU. I
> described several execution unit in the .cpu, with different timing, but it
> seems the latency of the instructions has no effect on the execution
> scheduler. The sched tick is incremented by 1 at each instruction regardless
> of latency of the execution unit.
>
> How can I do? Where are the timing information saved ?
>
> Thanks,
> Aurélien
>
>
>
>
>   

^ permalink raw reply	[flat|nested] 7+ messages in thread

* RE: timings in sid
  2008-10-09 16:24     ` Dave Brolley
@ 2008-10-10 16:29       ` Aurélien Buhrig
  2008-10-10 16:42         ` Frank Ch. Eigler
  0 siblings, 1 reply; 7+ messages in thread
From: Aurélien Buhrig @ 2008-10-10 16:29 UTC (permalink / raw)
  To: 'Dave Brolley'; +Cc: sid

Thanks for your reply.

My real problem was to figure out where could I find timings in cgen
generated files. I found actually I had to generate the model files, and I
used MEP and SH as example, even mine is much simpler.

BTW, are there only the MEP and SH platforms which correctly handle
execution time and can be used with peripherals in SID?

Aurélien



^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: timings in sid
  2008-10-10 16:29       ` Aurélien Buhrig
@ 2008-10-10 16:42         ` Frank Ch. Eigler
  0 siblings, 0 replies; 7+ messages in thread
From: Frank Ch. Eigler @ 2008-10-10 16:42 UTC (permalink / raw)
  To: Aurélien Buhrig; +Cc: 'Dave Brolley', sid

Hi -

On Fri, Oct 10, 2008 at 06:28:15PM +0200, Aurélien Buhrig wrote:
> Thanks for your reply.
> [...]
> BTW, are there only the MEP and SH platforms which correctly handle
> execution time and can be used with peripherals in SID?

Those are the ones where instruction timing is calculated from the
model.  For your model, you can calculate it yourself any way you
like, as long as you use the same signaling convention (pin data value
being sent back to the scheduler) to indicate the amount of time taken
by the current instruction (sequence).

- FChE

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2008-10-10 16:42 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-09-17  8:58 component_library object not found in lib Aurélien Buhrig
2008-09-17 13:45 ` Frank Ch. Eigler
2008-09-17 16:20   ` Aurélien Buhrig
2008-10-09  9:32   ` timings in sid Aurélien Buhrig
2008-10-09 16:24     ` Dave Brolley
2008-10-10 16:29       ` Aurélien Buhrig
2008-10-10 16:42         ` Frank Ch. Eigler

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).