Skip to content

Commit

Permalink
Update patches
Browse files Browse the repository at this point in the history
  • Loading branch information
smoelius committed Oct 3, 2024
1 parent fefc158 commit baf1a09
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 12 deletions.
16 changes: 8 additions & 8 deletions third-party/patches/solana_rbpf.patch
Original file line number Diff line number Diff line change
Expand Up @@ -357,7 +357,7 @@ index e864855..a8a44e6 100644
struct MappingCache {
// The cached entries.
diff --git a/src/program.rs b/src/program.rs
index 0ef76bc..3359e31 100644
index cc80ec2..6f052ad 100644
--- a/src/program.rs
+++ b/src/program.rs
@@ -10,5 +10,5 @@ use {
Expand All @@ -367,14 +367,14 @@ index 0ef76bc..3359e31 100644
+#[derive(Debug, PartialEq, PartialOrd, Eq, Clone, Copy, serde::Deserialize, serde::Serialize)]
pub enum SBPFVersion {
/// The legacy format
@@ -289,5 +289,5 @@ impl<C: ContextObject> std::fmt::Debug for BuiltinProgram<C> {
@@ -287,5 +287,5 @@ impl<C: ContextObject> std::fmt::Debug for BuiltinProgram<C> {
#[macro_export]
macro_rules! declare_builtin_function {
- ($(#[$attr:meta])* $name:ident $(<$($generic_ident:tt : $generic_type:tt),+>)?, fn rust(
+ ($(#[$attr:meta])* $name:ident, fn rust $(<$($lifetime:tt),+>)? (
$vm:ident : &mut $ContextObject:ty,
$arg_a:ident : u64,
@@ -300,7 +300,9 @@ macro_rules! declare_builtin_function {
@@ -298,7 +298,9 @@ macro_rules! declare_builtin_function {
$(#[$attr])*
pub struct $name {}
+ #[test_fuzz::test_fuzz_impl]
Expand All @@ -385,7 +385,7 @@ index 0ef76bc..3359e31 100644
+ pub fn rust $(<$($lifetime),+>)? (
$vm: &mut $ContextObject,
$arg_a: u64,
@@ -311,9 +313,12 @@ macro_rules! declare_builtin_function {
@@ -309,9 +311,12 @@ macro_rules! declare_builtin_function {
$memory_mapping: &mut $MemoryMapping,
) -> $Result {
+ if matches!($memory_mapping, MemoryMapping::Identity) {
Expand All @@ -399,14 +399,14 @@ index 0ef76bc..3359e31 100644
+ pub fn vm $(<$($lifetime),+>)? (
$vm: *mut $crate::vm::EbpfVm<$ContextObject>,
$arg_a: u64,
@@ -325,5 +330,5 @@ macro_rules! declare_builtin_function {
@@ -323,5 +328,5 @@ macro_rules! declare_builtin_function {
use $crate::vm::ContextObject;
let vm = unsafe {
- &mut *($vm.cast::<u64>().offset(-($crate::vm::get_runtime_environment_key() as isize)).cast::<$crate::vm::EbpfVm<$ContextObject>>())
+ &mut *(($vm as *mut u64).offset(-($crate::vm::get_runtime_environment_key() as isize)) as *mut $crate::vm::EbpfVm<$ContextObject>)
};
let config = vm.loader.get_config();
@@ -331,5 +336,5 @@ macro_rules! declare_builtin_function {
@@ -329,5 +334,5 @@ macro_rules! declare_builtin_function {
vm.context_object_pointer.consume(vm.previous_instruction_meter - vm.due_insn_count);
}
- let converted_result: $crate::error::ProgramResult = Self::rust $(::<$($generic_ident),+>)?(
Expand Down Expand Up @@ -502,7 +502,7 @@ index a8d398d..98f35a4 100644
) -> Result<u64, Box<dyn std::error::Error>> {
println!(
diff --git a/src/vm.rs b/src/vm.rs
index 969a339..a5e1a2c 100644
index f4a9a15..01ded61 100644
--- a/src/vm.rs
+++ b/src/vm.rs
@@ -49,5 +49,5 @@ pub fn get_runtime_environment_key() -> i32 {
Expand All @@ -512,7 +512,7 @@ index 969a339..a5e1a2c 100644
+#[derive(Debug, Clone, PartialEq, Eq, serde::Deserialize, serde::Serialize)]
pub struct Config {
/// Maximum call depth
@@ -145,5 +145,5 @@ pub trait ContextObject {
@@ -139,5 +139,5 @@ pub trait ContextObject {

/// Simple instruction meter for testing
-#[derive(Debug, Clone, Default)]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ index b4a5d9e..f43a43d 100644
ready: &mut ReadyTransactions<H, Ex>,
tx: Transaction<H, Ex>,
diff --git a/substrate/client/transaction-pool/src/graph/tracked_map.rs b/substrate/client/transaction-pool/src/graph/tracked_map.rs
index 47ad226..41b184e 100644
index 44c2c73..b616365 100644
--- a/substrate/client/transaction-pool/src/graph/tracked_map.rs
+++ b/substrate/client/transaction-pool/src/graph/tracked_map.rs
@@ -34,6 +34,9 @@ pub trait Size {
Expand Down
6 changes: 3 additions & 3 deletions third-party/third_party.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
{
"flags": ["EXPENSIVE", "SKIP_NIGHTLY"],
"url": "https://github.com/anza-xyz/agave",
"rev": "443246dee0ec0cacea08d8bc63eed7d4e57089f7",
"rev": "83e7d84bcc4cf438905d07279bc07e012a49afd9",
"patch": "agave.patch",
"subdir": ".",
"package": "solana-bpf-loader-program",
Expand All @@ -20,7 +20,7 @@
{
"flags": ["EXPENSIVE", "SKIP_NIGHTLY"],
"url": "https://github.com/paritytech/polkadot-sdk",
"rev": "f6d08e637694729df7cddb166954ee90c2da3ce1",
"rev": "8614dc0e055d06de4a3774ac1da0a422b33f34e2",
"patch": "substrate_client_transaction_pool.patch",
"subdir": ".",
"package": "sc-transaction-pool",
Expand All @@ -38,7 +38,7 @@
{
"flags": [],
"url": "https://github.com/solana-labs/rbpf",
"rev": "57139e9e1fca4f01155f7d99bc55cdcc25b0bc04",
"rev": "073c6607d958391713e9fb6d8f756e531224a0ad",
"patch": "solana_rbpf.patch",
"subdir": ".",
"package": "solana_rbpf",
Expand Down

0 comments on commit baf1a09

Please sign in to comment.