This repository was archived by the owner on Jan 22, 2025. It is now read-only.
Commit af2ad66 1 parent 8bd12f4 commit af2ad66 Copy full SHA for af2ad66
File tree 1 file changed +8
-10
lines changed
programs/bpf_loader/src/syscalls
1 file changed +8
-10
lines changed Original file line number Diff line number Diff line change @@ -1638,9 +1638,7 @@ declare_syscall!(
1638
1638
memory_mapping: & mut MemoryMapping ,
1639
1639
) -> Result <u64 , EbpfError > {
1640
1640
use solana_sdk:: alt_bn128:: prelude:: { ALT_BN128_ADD , ALT_BN128_MUL , ALT_BN128_PAIRING } ;
1641
-
1642
1641
let budget = invoke_context. get_compute_budget( ) ;
1643
-
1644
1642
let ( cost, output) : ( u64 , usize ) = match group_op {
1645
1643
ALT_BN128_ADD => (
1646
1644
budget. alt_bn128_addition_cost,
@@ -1669,15 +1667,15 @@ declare_syscall!(
1669
1667
}
1670
1668
} ;
1671
1669
1672
- invoke_context . get_compute_meter ( ) . consume ( cost) ?;
1670
+ consume_compute_meter ( invoke_context , cost) ?;
1673
1671
1674
- let call_result = translate_slice_mut :: <u8 >(
1675
- memory_mapping,
1676
- result_addr ,
1677
- ALT_BN128_MULTIPLICATION_OUTPUT_LEN as u64 ,
1678
- invoke_context. get_check_aligned( ) ,
1679
- invoke_context. get_check_size( ) ,
1680
- ) ?;
1672
+ let input = translate_slice :: <u8 >(
1673
+ memory_mapping,
1674
+ input_addr ,
1675
+ input_size ,
1676
+ invoke_context. get_check_aligned( ) ,
1677
+ invoke_context. get_check_size( ) ,
1678
+ ) ?;
1681
1679
1682
1680
let call_result = translate_slice_mut:: <u8 >(
1683
1681
memory_mapping,
You can’t perform that action at this time.
0 commit comments