[foreign] RFR: refresh layout grammar

Maurizio Cimadamore maurizio.cimadamore at oracle.com
Wed May 23 16:46:40 UTC 2018


Hi,
I've put together a change which tweaks the grammar of layout 
descriptions used in annotations to correspond to what's described here [1].

The big changes are in DescriptorParser, which now has to understand the 
new grammar, and also in TestDescriptorGrammar, which has to 
combinatorially generate sentences of the new grammar.

All the other tedious changes are test changes, required to go from the 
old to the new grammar; I've adhered to the following rules:

'b' -> 'u8'
'c' -> 'i8'
's' -> 'i16'
'i' -> 'i32'
'l' -> 'i64'
'q' -> 'i64'

Also note that in the new grammar capital letter denote big-endiannes, 
while in the old one they meant unsigned-ness.

There's a trivia in the DoubleUpcall test, which was using 'unsigned 
double' ('D') - not sure why...

Webrev here:

http://cr.openjdk.java.net/~mcimadamore/panama/layout-grammar-refresh/

P.S.
Might be useful to give it a spin on Mac and see if UnixSystemTest works 
(the layout conversion was not very trivial w/o jextract support :-))

Cheers

Maurizio




More information about the panama-dev mailing list