mirror of
				https://github.com/rust-lang/rust-analyzer.git
				synced 2025-10-31 03:54:42 +00:00 
			
		
		
		
	Merge pull request #19083 from he32/fix-arm64-be
line-index: don't try to use (unavailable) neon on big-endian aarch64
This commit is contained in:
		
						commit
						ed1d4092a7
					
				
					 1 changed files with 8 additions and 4 deletions
				
			
		|  | @ -235,7 +235,7 @@ fn analyze_source_file_dispatch( | ||||||
|     } |     } | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| #[cfg(target_arch = "aarch64")] | #[cfg(all(target_arch = "aarch64", target_endian = "little"))] | ||||||
| fn analyze_source_file_dispatch( | fn analyze_source_file_dispatch( | ||||||
|     src: &str, |     src: &str, | ||||||
|     lines: &mut Vec<TextSize>, |     lines: &mut Vec<TextSize>, | ||||||
|  | @ -347,7 +347,7 @@ unsafe fn analyze_source_file_sse2( | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| #[target_feature(enable = "neon")] | #[target_feature(enable = "neon")] | ||||||
| #[cfg(target_arch = "aarch64")] | #[cfg(all(target_arch = "aarch64", target_endian = "little"))] | ||||||
| #[inline] | #[inline] | ||||||
| // See https://community.arm.com/arm-community-blogs/b/infrastructure-solutions-blog/posts/porting-x86-vector-bitmask-optimizations-to-arm-neon
 | // See https://community.arm.com/arm-community-blogs/b/infrastructure-solutions-blog/posts/porting-x86-vector-bitmask-optimizations-to-arm-neon
 | ||||||
| //
 | //
 | ||||||
|  | @ -362,7 +362,7 @@ unsafe fn move_mask(v: std::arch::aarch64::uint8x16_t) -> u64 { | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| #[target_feature(enable = "neon")] | #[target_feature(enable = "neon")] | ||||||
| #[cfg(target_arch = "aarch64")] | #[cfg(all(target_arch = "aarch64", target_endian = "little"))] | ||||||
| unsafe fn analyze_source_file_neon( | unsafe fn analyze_source_file_neon( | ||||||
|     src: &str, |     src: &str, | ||||||
|     lines: &mut Vec<TextSize>, |     lines: &mut Vec<TextSize>, | ||||||
|  | @ -441,7 +441,11 @@ unsafe fn analyze_source_file_neon( | ||||||
|     } |     } | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| #[cfg(not(any(target_arch = "x86", target_arch = "x86_64", target_arch = "aarch64")))] | #[cfg(not(any(
 | ||||||
|  |     target_arch = "x86", | ||||||
|  |     target_arch = "x86_64", | ||||||
|  |     all(target_arch = "aarch64", target_endian = "little") | ||||||
|  | )))] | ||||||
| // The target (or compiler version) does not support SSE2 ...
 | // The target (or compiler version) does not support SSE2 ...
 | ||||||
| fn analyze_source_file_dispatch( | fn analyze_source_file_dispatch( | ||||||
|     src: &str, |     src: &str, | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Laurențiu Nicola
						Laurențiu Nicola