review request (L): 7030453: JSR 292 ClassValue.get method is too slow (original) (raw)
Rémi Forax forax at univ-mlv.fr
Sun Dec 4 22:13:39 UTC 2011
- Previous message: review request (L): 7030453: JSR 292 ClassValue.get method is too slow
- Next message: review request (L): 7030453: JSR 292 ClassValue.get method is too slow
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On 12/04/2011 08:38 PM, Joe Darcy wrote:
Hi John,
Are there alternatives to adding two new fields to java.lang.Class? I assume most Class'es won't have ClassValue information associated with them. -Joe
If you use Groovy, JRuby or Nashorn in your code, all visible classes will use this two fields.
Any alternative will slow down the access to the class value.
BTW, if we had to remove some fields, I vote for moving all fields related to the reflection in a delegate class. Looking up for members is slow so most of the code that call reflection methods use their own cache, so the performance impact will be small in my opinion (I have no data to prove that :)
Rémi
- Previous message: review request (L): 7030453: JSR 292 ClassValue.get method is too slow
- Next message: review request (L): 7030453: JSR 292 ClassValue.get method is too slow
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]