src/cpu/x86/vm/x86_64.ad

Print this page




6323   match(StoreFence);
6324   ins_cost(0);
6325 
6326   size(0);
6327   format %{ "MEMBAR-release ! (empty encoding)" %}
6328   ins_encode();
6329   ins_pipe(empty);
6330 %}
6331 
6332 instruct membar_release_lock()
6333 %{
6334   match(MemBarReleaseLock);
6335   ins_cost(0);
6336 
6337   size(0);
6338   format %{ "MEMBAR-release (a FastUnlock follows so empty encoding)" %}
6339   ins_encode();
6340   ins_pipe(empty);
6341 %}
6342 



















6343 instruct membar_volatile(rFlagsReg cr) %{
6344   match(MemBarVolatile);
6345   effect(KILL cr);
6346   ins_cost(400);
6347 
6348   format %{
6349     $$template
6350     if (os::is_MP()) {
6351       $$emit$$"lock addl [rsp + #0], 0\t! membar_volatile"
6352     } else {
6353       $$emit$$"MEMBAR-volatile ! (empty encoding)"
6354     }
6355   %}
6356   ins_encode %{
6357     __ membar(Assembler::StoreLoad);
6358   %}
6359   ins_pipe(pipe_slow);
6360 %}
6361 
6362 instruct unnecessary_membar_volatile()




6323   match(StoreFence);
6324   ins_cost(0);
6325 
6326   size(0);
6327   format %{ "MEMBAR-release ! (empty encoding)" %}
6328   ins_encode();
6329   ins_pipe(empty);
6330 %}
6331 
6332 instruct membar_release_lock()
6333 %{
6334   match(MemBarReleaseLock);
6335   ins_cost(0);
6336 
6337   size(0);
6338   format %{ "MEMBAR-release (a FastUnlock follows so empty encoding)" %}
6339   ins_encode();
6340   ins_pipe(empty);
6341 %}
6342 
6343 instruct onspinwait()
6344 %{
6345   match(OnSpinWait);
6346   ins_cost(200);
6347 
6348   format %{
6349     $$template
6350     if (os::is_MP()) {
6351       $$emit$$"pause\t! membar_onspinwait"
6352     } else {
6353       $$emit$$"MEMBAR-onspinwait ! (empty encoding)"
6354     }
6355   %}
6356   ins_encode %{
6357     __ pause();
6358   %}
6359   ins_pipe(pipe_slow);
6360 %}
6361 
6362 instruct membar_volatile(rFlagsReg cr) %{
6363   match(MemBarVolatile);
6364   effect(KILL cr);
6365   ins_cost(400);
6366 
6367   format %{
6368     $$template
6369     if (os::is_MP()) {
6370       $$emit$$"lock addl [rsp + #0], 0\t! membar_volatile"
6371     } else {
6372       $$emit$$"MEMBAR-volatile ! (empty encoding)"
6373     }
6374   %}
6375   ins_encode %{
6376     __ membar(Assembler::StoreLoad);
6377   %}
6378   ins_pipe(pipe_slow);
6379 %}
6380 
6381 instruct unnecessary_membar_volatile()