context : simplify setters (#29730)
This commit is contained in:
1 parent
6b00d5627b
commit
cd8427d018
1 file changed
+2
-12
+2
-12
@@ -1379,14 +1379,9 @@ void llama_context::set_nextn_layer_offset(int32_t offset) {
|
||||
void llama_context::set_causal_attn(bool value) {
|
||||
LLAMA_LOG_DEBUG("%s: value = %d\n", __func__, value);
|
||||
|
||||
if (cparams.causal_attn == value) {
|
||||
return;
|
||||
}
|
||||
// no scheduler reserve needed because graph shapes must not depend on causal_attn, a flip only rebuilds the graph
|
||||
|
||||
cparams.causal_attn = value;
|
||||
|
||||
// no scheduler reserve needed because graph shapes must not depend on causal_attn, a flip only rebuilds the graph
|
||||
//sched_need_reserve = true;
|
||||
}
|
||||
|
||||
bool llama_context::get_causal_attn() const {
|
||||
@@ -1396,14 +1391,9 @@ bool llama_context::get_causal_attn() const {
|
||||
void llama_context::set_warmup(bool value) {
|
||||
LLAMA_LOG_DEBUG("%s: value = %d\n", __func__, value);
|
||||
|
||||
if (cparams.warmup == value) {
|
||||
return;
|
||||
}
|
||||
// no scheduler reserve needed because warmups are usually with small batches
|
||||
|
||||
cparams.warmup = value;
|
||||
|
||||
// warmups are usually with small batches, so no need to reserve
|
||||
//sched_need_reserve = true;
|
||||
}
|
||||
|
||||
bool llama_context::set_sampler(llama_seq_id seq_id, llama_sampler * sampler) {
|
||||
|
||||
Reference in new issue
Block a user