Add GPU sigverify for verify path (#20851)

Allows the use of GPU acceleration in verifying the signatures in Entry's after deserialization in the replay stage

Co-authored-by: Stephen Akridge <sakridge@gmail.com>
Co-authored-by: Ryan Leung <ryan.leung@solana.com>
This commit is contained in:
ryleung-solana
2021-11-30 21:16:13 -05:00
committed by GitHub
parent 8d0357794e
commit 8cf36e5cb0
9 changed files with 573 additions and 56 deletions

View File

@ -127,6 +127,13 @@ pub enum TransactionError {
WouldExceedMaxAccountCostLimit,
}
#[derive(PartialEq, Clone, Copy, Debug)]
pub enum TransactionVerificationMode {
HashOnly,
HashAndVerifyPrecompiles,
FullVerification,
}
pub type Result<T> = result::Result<T, TransactionError>;
impl From<SanitizeError> for TransactionError {
@ -404,6 +411,10 @@ impl Transaction {
}
}
pub fn get_invalid_signature() -> Signature {
Signature::default()
}
/// Verify the length of signatures matches the value in the message header
pub fn verify_signatures_len(&self) -> bool {
self.signatures.len() == self.message.header.num_required_signatures as usize