nak: Fix a bunch of warnings
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24998>
This commit is contained in:
committed by
Marge Bot
parent
09d78e8572
commit
c87693a700
@@ -28,7 +28,6 @@ mod util;
|
||||
|
||||
use crate::nak_ir::ShaderStageInfo;
|
||||
|
||||
use bitview::*;
|
||||
use nak_bindings::*;
|
||||
use nak_from_nir::*;
|
||||
use nak_ir::ShaderIoInfo;
|
||||
@@ -164,7 +163,7 @@ pub extern "C" fn nak_compiler_destroy(nak: *mut nak_compiler) {
|
||||
}
|
||||
|
||||
#[no_mangle]
|
||||
pub extern "C" fn nak_debug_flags(nak: *const nak_compiler) -> u64 {
|
||||
pub extern "C" fn nak_debug_flags(_nak: *const nak_compiler) -> u64 {
|
||||
DEBUG.debug_flags().into()
|
||||
}
|
||||
|
||||
|
||||
@@ -129,10 +129,6 @@ impl BarAlloc {
|
||||
self.wr_bars & (1 << bar) != 0
|
||||
}
|
||||
|
||||
pub fn is_rd_bar(&self, bar: u8) -> bool {
|
||||
!self.is_wr_bar(bar)
|
||||
}
|
||||
|
||||
pub fn get_bar(&self, dep: usize) -> Option<u8> {
|
||||
let bar = self.dep_bar[dep];
|
||||
if bar == u8::MAX {
|
||||
|
||||
@@ -1708,12 +1708,12 @@ impl SM75Instr {
|
||||
self.set_reg_src(24..32, op.idx);
|
||||
}
|
||||
|
||||
fn encode_kill(&mut self, op: &OpKill) {
|
||||
fn encode_kill(&mut self, _op: &OpKill) {
|
||||
self.set_opcode(0x95b);
|
||||
self.set_pred_src(87..90, 90, SrcRef::True.into());
|
||||
}
|
||||
|
||||
fn encode_nop(&mut self, op: &OpNop) {
|
||||
fn encode_nop(&mut self, _op: &OpNop) {
|
||||
self.set_opcode(0x918);
|
||||
}
|
||||
|
||||
|
||||
@@ -6,8 +6,6 @@
|
||||
#![allow(non_upper_case_globals)]
|
||||
#![allow(unstable_name_collisions)]
|
||||
|
||||
use crate::bitset::BitSet;
|
||||
use crate::bitview::{BitMutView, BitView, SetField};
|
||||
use crate::nak_cfg::CFGBuilder;
|
||||
use crate::nak_ir::*;
|
||||
use crate::nak_sph::{OutputTopology, PixelImap};
|
||||
@@ -1825,7 +1823,7 @@ impl<'a> ShaderFromNir<'a> {
|
||||
});
|
||||
}
|
||||
nir_intrinsic_store_output => {
|
||||
let ShaderIoInfo::Fragment(io) = &mut self.info.io else {
|
||||
let ShaderIoInfo::Fragment(_) = &mut self.info.io else {
|
||||
panic!("load_input is only used for fragment shaders");
|
||||
};
|
||||
let data = self.get_src(&srcs[0]);
|
||||
@@ -2188,7 +2186,7 @@ impl<'a> ShaderFromNir<'a> {
|
||||
|
||||
self.parse_cf_list(&mut ssa_alloc, &mut phi_map, nfi.iter_body());
|
||||
|
||||
let mut cfg = std::mem::take(&mut self.cfg).as_cfg();
|
||||
let cfg = std::mem::take(&mut self.cfg).as_cfg();
|
||||
assert!(cfg.len() > 0);
|
||||
for i in 0..cfg.len() {
|
||||
if cfg[i].falls_through() {
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
|
||||
extern crate nak_ir_proc;
|
||||
|
||||
use crate::bitview::{BitMutView, SetField};
|
||||
use crate::bitview::{BitMutView};
|
||||
pub use crate::nak_builder::{
|
||||
Builder, InstrBuilder, SSABuilder, SSAInstrBuilder,
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user