lightning
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Lightning] Re: Predicting generated code size


From: Paolo Bonzini
Subject: [Lightning] Re: Predicting generated code size
Date: Sun, 30 Sep 2007 20:06:46 +0200
User-agent: Thunderbird 2.0.0.6 (Macintosh/20070728)

Sandro Magi wrote:
On 9/28/07, Ludovic Courtès <address@hidden> wrote:
Or perhaps, some technique to chain buffers together and auto-insert a
jmp to the next buffer address when the current buffer is full?
That's another possibility.  It makes code generation faster, compared
to reallocating a new buffer and restarting from scratch, but it might
be cache-unfriendly.

Hmm, I would expect branch prediction rate to be 100% since it's an
unconditional jump, so it should only be a minor hit, if any.

Yes, this is probably the best thing to do. You can expect more or less an instruction to take at most 20 bytes, I'd say, surely less than 32.

Paolo





reply via email to

[Prev in Thread] Current Thread [Next in Thread]