Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
gaoqiong
flash-attention
Commits
264a683d
Commit
264a683d
authored
May 19, 2024
by
Woosuk Kwon
Browse files
Fix typo
parent
50601bf4
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
csrc/flash_attn/src/utils.h
csrc/flash_attn/src/utils.h
+1
-1
No files found.
csrc/flash_attn/src/utils.h
View file @
264a683d
...
...
@@ -307,7 +307,7 @@ int64_t resolve_thread_kv_page_slice_offset(const int tidx, const int n_block_ma
const
int64_t
block_row_offset
=
tidx
/
kGmemThreadsPerRow
*
kGmemRowsPerThread
;
const
int64_t
global_row_offset
=
block_row_offset
+
(
n_block_max
-
1
)
*
kBlockN
;
const
int64_t
page_offset
=
global_row_offset
%
page_block_size
;
const
int6
5
_t
virtual_page_idx
=
global_row_offset
/
page_block_size
;
const
int6
4
_t
virtual_page_idx
=
global_row_offset
/
page_block_size
;
return
((
int64_t
)
block_table
[
virtual_page_idx
])
*
((
int64_t
)
page_stride
)
+
page_offset
*
((
int64_t
)
row_stride
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment