Skip to content
This repository has been archived by the owner on Jan 10, 2025. It is now read-only.

Limit - Reduce SYMBOL_NAME_LENGTH_MAXIMUM to 64 #470

Merged
merged 1 commit into from
Jun 1, 2023

Conversation

Lichtso
Copy link

@Lichtso Lichtso commented Jun 1, 2023

No description provided.

@Lichtso Lichtso requested a review from alessandrod June 1, 2023 09:05
@Lichtso Lichtso merged commit cb78815 into main Jun 1, 2023
@Lichtso Lichtso deleted the limit/reduce_max_symbol_name_length branch June 1, 2023 09:50
@@ -9,7 +9,7 @@ use crate::{ArithmeticOverflow, ErrCheckedArithmetic};
use {consts::*, types::*};

const SECTION_NAME_LENGTH_MAXIMUM: usize = 16;
const SYMBOL_NAME_LENGTH_MAXIMUM: usize = 1024;
const SYMBOL_NAME_LENGTH_MAXIMUM: usize = 64;

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change makes it impossible to load files generated by our Move compiler. For example, this relocation triggers Unknown symbol error.

0000000000000578  000000250000000a R_BPF_64_32            000000000008d940 _ZN4core3fmt3num53_$LT$impl$u20$core..fmt..UpperHex$u20$for$u20$u16$GT$3fmt17hda2568c893a78314E

The symbol is 95 characters long. There are longer symbols in Move compiled modules too.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants