-
Notifications
You must be signed in to change notification settings - Fork 26
[CB] remove VLLM_SPYRE_RM_PADDED_BLOCKS, enable the feature by default #231
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 2 commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
cb861d1
remove VLLM_SPYRE_RM_PADDED_BLOCKS, enable the feature by default
yannicks1 5083348
fix cb tests
yannicks1 f49f322
remove left padding stripping test, as now obsolete
yannicks1 4e16e91
commenting resetting of tkv due to padded block removal
yannicks1 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -136,7 +136,6 @@ def get_params_test_blocks_borders_aligned_prompts(): | |
| prompts_lengths = [49, 41, 47] | ||
| steps_add_reqs = [0, 0, 0] # add all requests in the beginning | ||
| max_model_len = 2048 | ||
| remove_left_padding = False | ||
|
|
||
| checked_steps = [ | ||
| { | ||
|
|
@@ -203,7 +202,7 @@ def get_params_test_blocks_borders_aligned_prompts(): | |
| }, | ||
| { | ||
| "step": 70, # Decode sequence 2 | ||
| "tkv": 131, | ||
| "tkv": 67, | ||
|
||
| "waiting": [], | ||
| "running": ["2"], | ||
| "request_outputs": ["2"] | ||
|
|
@@ -212,7 +211,7 @@ def get_params_test_blocks_borders_aligned_prompts(): | |
| # Sequence 2 finishes at step 73 | ||
| # (start step + 1 prefill + 6 decodes - 1) = 67 + 1 + 6 - 1 = 73 | ||
| "step": 73, | ||
| "tkv": 134, | ||
| "tkv": 70, | ||
prashantgupta24 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| "waiting": [], | ||
| "running": [], | ||
| "request_outputs": ["2"], | ||
|
|
@@ -229,7 +228,7 @@ def get_params_test_blocks_borders_aligned_prompts(): | |
| ] | ||
|
|
||
| return (seqs_max_tokens, prompts_lengths, steps_add_reqs, checked_steps, | ||
| max_model_len, remove_left_padding) | ||
| max_model_len) | ||
|
|
||
|
|
||
| def get_params_test_blocks_borders_misaligned_prompts(): | ||
|
|
@@ -241,7 +240,6 @@ def get_params_test_blocks_borders_misaligned_prompts(): | |
| prompts_lengths = [49, 41, 47] | ||
| steps_add_reqs = [0, 0, 0] # add all requests in the beginning | ||
| max_model_len = 2048 | ||
| remove_left_padding = False | ||
|
|
||
| checked_steps = [ | ||
| { | ||
|
|
@@ -334,7 +332,7 @@ def get_params_test_blocks_borders_misaligned_prompts(): | |
| ] | ||
|
|
||
| return (seqs_max_tokens, prompts_lengths, steps_add_reqs, checked_steps, | ||
| max_model_len, remove_left_padding) | ||
| max_model_len) | ||
|
|
||
|
|
||
| def get_params_test_special_finish(): | ||
|
|
@@ -345,7 +343,6 @@ def get_params_test_special_finish(): | |
| prompts_lengths = [49, 30, 20] | ||
| steps_add_reqs = [0, 0, 31] | ||
| max_model_len = 2048 | ||
| remove_left_padding = False | ||
|
|
||
| checked_steps = [ | ||
| { | ||
|
|
@@ -426,7 +423,7 @@ def get_params_test_special_finish(): | |
| ] | ||
|
|
||
| return (seqs_max_tokens, prompts_lengths, steps_add_reqs, checked_steps, | ||
| max_model_len, remove_left_padding) | ||
| max_model_len) | ||
|
|
||
|
|
||
| def get_params_test_scheduler_constraints_tkv(): | ||
|
|
@@ -436,7 +433,6 @@ def get_params_test_scheduler_constraints_tkv(): | |
| prompts_lengths = [49, 70] | ||
| steps_add_reqs = [0, 0] | ||
| max_model_len = 2048 | ||
| remove_left_padding = False | ||
|
|
||
| checked_steps = [ | ||
| { | ||
|
|
@@ -518,7 +514,7 @@ def get_params_test_scheduler_constraints_tkv(): | |
| ] | ||
|
|
||
| return (seqs_max_tokens, prompts_lengths, steps_add_reqs, checked_steps, | ||
| max_model_len, remove_left_padding) | ||
| max_model_len) | ||
|
|
||
|
|
||
| def get_params_test_scheduler_constraints_max_prompt_len(): | ||
|
|
@@ -528,7 +524,6 @@ def get_params_test_scheduler_constraints_max_prompt_len(): | |
| prompts_lengths = [70, 49, 41] | ||
| steps_add_reqs = [0, 0, 0] | ||
| max_model_len = 256 | ||
| remove_left_padding = False | ||
|
|
||
| checked_steps = [ | ||
| { | ||
|
|
@@ -628,7 +623,7 @@ def get_params_test_scheduler_constraints_max_prompt_len(): | |
| ] | ||
|
|
||
| return (seqs_max_tokens, prompts_lengths, steps_add_reqs, checked_steps, | ||
| max_model_len, remove_left_padding) | ||
| max_model_len) | ||
|
|
||
|
|
||
| def get_params_test_remove_left_padding(): | ||
|
|
@@ -638,7 +633,6 @@ def get_params_test_remove_left_padding(): | |
| prompts_lengths = [20, 14, 5] | ||
| steps_add_reqs = [0, 30, 31] | ||
| max_model_len = 2048 | ||
| remove_left_padding = True | ||
|
|
||
| checked_steps = [ | ||
| { | ||
|
|
@@ -745,7 +739,7 @@ def get_params_test_remove_left_padding(): | |
| ] | ||
|
|
||
| return (seqs_max_tokens, prompts_lengths, steps_add_reqs, checked_steps, | ||
| max_model_len, remove_left_padding) | ||
| max_model_len) | ||
|
|
||
|
|
||
| def augment_checked_steps( | ||
|
|
@@ -775,7 +769,7 @@ def augment_checked_steps( | |
| @pytest.mark.parametrize("max_num_seqs", [2]) | ||
| @pytest.mark.parametrize( | ||
| "seqs_max_tokens,prompts_lengths,steps_add_reqs,checked_steps," | ||
| "max_model_len,remove_left_padding", [ | ||
| "max_model_len", [ | ||
| get_params_test_blocks_borders_aligned_prompts(), | ||
| get_params_test_blocks_borders_misaligned_prompts(), | ||
| get_params_test_special_finish(), | ||
|
|
@@ -793,7 +787,6 @@ def test_scheduler_cb_steps_tkv( | |
| steps_add_reqs: list[int], | ||
| checked_steps: list[dict[str, Any]], | ||
| max_model_len: int, | ||
| remove_left_padding: bool, | ||
| ): | ||
| """ | ||
| Test the scheduler execution by comparing the scheduler attributes at each | ||
|
|
@@ -809,8 +802,6 @@ def test_scheduler_cb_steps_tkv( | |
| monkeypatch.setenv("VLLM_SPYRE_USE_CB", "1") | ||
| monkeypatch.setenv("VLLM_USE_V1", "1") | ||
| monkeypatch.setenv("VLLM_SPYRE_DYNAMO_BACKEND", backend) | ||
| monkeypatch.setenv("VLLM_SPYRE_RM_PADDED_BLOCKS", | ||
| "1" if remove_left_padding else "0") | ||
|
|
||
| # To get deterministic execution in V1 | ||
| # and to enable InprocClient | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure if
get_params_test_remove_left_paddingstill has any value left since removing the left padding is the default cc @sducouedicThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
good point, do you agree @sducouedic ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yep we should remove that one