Examples of ret()


Examples of com.facebook.presto.byteCode.Block.ret()

        for (StateField field : fields) {
            fieldDefinitions.add(generateGroupedField(definition, constructor, ensureCapacity, field));
        }

        constructor.ret();
        ensureCapacity.ret();

        // Generate getEstimatedSize
        Block getEstimatedSize = definition.declareMethod(new CompilerContext(null), a(PUBLIC), "getEstimatedSize", type(long.class))
                .getBody()
                .comment("long size = 0;")
View Full Code Here

Examples of com.facebook.presto.byteCode.Block.ret()

                    .invokeInterface(List.class, "get", Object.class, int.class)
                    .checkCast(type(List.class, com.facebook.presto.spi.block.Block.class))
                    .putField(joinChannelFields.get(index));
        }

        constructor.ret();
    }

    private void generateGetChannelCountMethod(ClassDefinition classDefinition, List<FieldDefinition> channelFields)
    {
        classDefinition.declareMethod(new CompilerContext(bootstrapMethod),
View Full Code Here

Examples of com.facebook.presto.byteCode.Block.ret()

                    .push(index)
                    .append(OpCodes.IADD)
                    .invokeVirtual(PageBuilder.class, "getBlockBuilder", BlockBuilder.class, int.class)
                    .invokeInterface(com.facebook.presto.spi.block.Block.class, "appendTo", void.class, int.class, BlockBuilder.class);
        }
        appendToBody.ret();
    }

    private void generateHashPositionMethod(ClassDefinition classDefinition, List<FieldDefinition> joinChannelFields)
    {
        MethodDefinition hashPositionMethod = classDefinition.declareMethod(new CompilerContext(bootstrapMethod),
View Full Code Here

Examples of com.facebook.presto.byteCode.Block.ret()

                    .pushThis()
                    .getField(stateField)
                    .getVariable("out")
                    .invokeInterface(AccumulatorStateSerializer.class, "serialize", void.class, Object.class, BlockBuilder.class);
        }
        body.ret();
    }

    private static void generateEvaluateFinal(
            ClassDefinition definition,
            MethodDefinition getFinalType,
View Full Code Here

Examples of com.facebook.presto.byteCode.Block.ret()

                    .cast(type(List.class, com.facebook.presto.spi.block.Block.class));

            constructor.append(compilerContext.getVariable("this").setField(joinChannelFields.get(index), joinChannel));
        }

        constructor.ret();
    }

    private void generateGetChannelCountMethod(ClassDefinition classDefinition, List<FieldDefinition> channelFields)
    {
        classDefinition.declareMethod(new CompilerContext(BOOTSTRAP_METHOD),
View Full Code Here

Examples of com.facebook.presto.byteCode.Block.ret()

                    .push(index)
                    .append(OpCodes.IADD)
                    .invokeVirtual(PageBuilder.class, "getBlockBuilder", BlockBuilder.class, int.class)
                    .invokeVirtual(type.getClass(), "appendTo", void.class, com.facebook.presto.spi.block.Block.class, int.class, BlockBuilder.class);
        }
        appendToBody.ret();
    }

    private void generateHashPositionMethod(ClassDefinition classDefinition, CallSiteBinder callSiteBinder, List<Type> joinChannelTypes, List<FieldDefinition> joinChannelFields)
    {
        CompilerContext compilerContext = new CompilerContext(BOOTSTRAP_METHOD);
View Full Code Here

Examples of com.facebook.presto.byteCode.Block.ret()

        }

        constructor.comment("this.position = -1;")
                .append(context.getVariable("this").setField(positionField, constantInt(-1)));

        constructor.ret();
    }

    private void generateGetChannelCountMethod(ClassDefinition classDefinition, int channelCount)
    {
        classDefinition.declareMethod(new CompilerContext(BOOTSTRAP_METHOD),
View Full Code Here

Examples of com.facebook.presto.byteCode.Block.ret()

                    .append(constantType(context, callSiteBinder, type).invoke("appendTo", void.class,
                            context.getVariable("this").getField(blockFields.get(index)),
                            context.getVariable("this").getField(positionField),
                            context.getVariable("pageBuilder").invoke("getBlockBuilder", BlockBuilder.class, constantInt(index))));
        }
        appendToBody.ret();
    }

    private void generateAdvanceNextPosition(ClassDefinition classDefinition, FieldDefinition positionField, FieldDefinition positionCountField)
    {
        CompilerContext context = new CompilerContext(BOOTSTRAP_METHOD);
View Full Code Here

Examples of com.facebook.presto.byteCode.Block.ret()

                    .cast(type(List.class, com.facebook.presto.spi.block.Block.class));

            constructor.append(compilerContext.getVariable("this").setField(joinChannelFields.get(index), joinChannel));
        }

        constructor.ret();
    }

    private void generateGetChannelCountMethod(ClassDefinition classDefinition, List<FieldDefinition> channelFields)
    {
        classDefinition.declareMethod(new CompilerContext(BOOTSTRAP_METHOD),
View Full Code Here

Examples of com.facebook.presto.byteCode.Block.ret()

                    .push(index)
                    .append(OpCode.IADD)
                    .invokeVirtual(PageBuilder.class, "getBlockBuilder", BlockBuilder.class, int.class)
                    .invokeInterface(Type.class, "appendTo", void.class, com.facebook.presto.spi.block.Block.class, int.class, BlockBuilder.class);
        }
        appendToBody.ret();
    }

    private void generateHashPositionMethod(ClassDefinition classDefinition, CallSiteBinder callSiteBinder, List<Type> joinChannelTypes, List<FieldDefinition> joinChannelFields)
    {
        CompilerContext compilerContext = new CompilerContext(BOOTSTRAP_METHOD);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.