Advertisement
mifeet

Streams API at bytecode level - rest of bytecode

Aug 24th, 2015
325
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 1.00 KB | None | 0 0
  1. Do-while loop:
  2.       49: aload_1
  3.       50: aload_2
  4.       51: iload_3
  5.       52: aaload
  6.       53: invokeinterface #69,  2           // InterfaceMethod java/util/function/Consumer.accept:(Ljava/lang/Object;)V
  7.       58: iinc          3, 1
  8.       61: iload_3
  9.       62: iload         4
  10.       64: if_icmplt     49
  11.  
  12. StatelessOp#accept() - wrapping the filter() operation
  13.       0: aload_0
  14.       1: getfield      #48                 // Field this$1:Ljava/util/stream/ReferencePipeline$2;
  15.       4: getfield      #47                 // Field java/util/stream/ReferencePipeline$2.val$predicate:Ljava/util/fnction/Predicate;
  16.       7: aload_1
  17.       8: invokeinterface #51,  2           // InterfaceMethod java/util/function/Predicate.test:(Ljava/lang/Object;
  18.      13: ifeq          26
  19.      16: aload_0
  20.      17: getfield      #49                 // Field downstream:Ljava/util/stream/Sink;
  21.      20: aload_1
  22.      21: invokeinterface #53,  2           // InterfaceMethod java/util/stream/Sink.accept:(Ljava/lang/Object;)V
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement