public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* Optimization of GAS
@ 2005-04-01 16:01 Stas Kiselev
  2005-04-01 16:35 ` Ian Lance Taylor
  2005-04-03 23:37 ` Ben Elliston
  0 siblings, 2 replies; 3+ messages in thread
From: Stas Kiselev @ 2005-04-01 16:01 UTC (permalink / raw)
  To: binutils

Hello,

I want to make GAS faster. I profiled it and found out that lots of the 
time takes on working with hash. What do you thing about changing hash 
mechanism into hash_map from stl. Will it work faster ?

Thank you, Stanislav



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

* Re: Optimization of GAS
  2005-04-01 16:01 Optimization of GAS Stas Kiselev
@ 2005-04-01 16:35 ` Ian Lance Taylor
  2005-04-03 23:37 ` Ben Elliston
  1 sibling, 0 replies; 3+ messages in thread
From: Ian Lance Taylor @ 2005-04-01 16:35 UTC (permalink / raw)
  To: Stas Kiselev; +Cc: binutils

Stas Kiselev <stas_kiselev@bk.ru> writes:

> I want to make GAS faster. I profiled it and found out that lots of the 
> time takes on working with hash. What do you thing about changing hash 
> mechanism into hash_map from stl. Will it work faster ?

STL is C++ code.  gas is written in C.  So using hash_map directly
would be rather difficult.

I expect that it is possible to speed up the hash code in gas.  It
would also be interesting to see if it can be called less often.  A
common usage is simply looking up instruction mnemonics, in which the
set of instructions is fixed at the start of assembly, and really, if
we do appropriate tests, it is fixed when the assembler is built.  Can
we take advantage of that, perhaps by doing perfect hashing?

Ian

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

* Re: Optimization of GAS
  2005-04-01 16:01 Optimization of GAS Stas Kiselev
  2005-04-01 16:35 ` Ian Lance Taylor
@ 2005-04-03 23:37 ` Ben Elliston
  1 sibling, 0 replies; 3+ messages in thread
From: Ben Elliston @ 2005-04-03 23:37 UTC (permalink / raw)
  To: binutils

> I want to make GAS faster. I profiled it and found out that lots of the 
> time takes on working with hash. What do you thing about changing hash 
> mechanism into hash_map from stl. Will it work faster ?

GAS really isn't a bottleneck on modern machines that have plenty of buffer cache.

I changed the GCC c-torture/compile.exp tests last year so that they just compiled 
rather than including the assembly step (ie. using -S instead of -c), thinking it 
would speed up those tests.  Over that large testsuite, the saving was less than 0.1%.

If you'd like to make something faster, work on the linker!

Ben

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

end of thread, other threads:[~2005-04-03 23:37 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-04-01 16:01 Optimization of GAS Stas Kiselev
2005-04-01 16:35 ` Ian Lance Taylor
2005-04-03 23:37 ` Ben Elliston

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).