2024-06-07 11:28:06 +08:00
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
< html xmlns = "http://www.w3.org/1999/xhtml" lang = "en-US" >
< head >
< meta http-equiv = "Content-Type" content = "text/xhtml;charset=UTF-8" / >
< meta http-equiv = "X-UA-Compatible" content = "IE=11" / >
< meta name = "generator" content = "Doxygen 1.10.0" / >
< meta name = "viewport" content = "width=device-width, initial-scale=1" / >
< title > MLX: mlx/backend/metal/utils.h File Reference< / title >
< link href = "tabs.css" rel = "stylesheet" type = "text/css" / >
< script type = "text/javascript" src = "jquery.js" > < / script >
< script type = "text/javascript" src = "dynsections.js" > < / script >
< script type = "text/javascript" src = "clipboard.js" > < / script >
< script type = "text/javascript" src = "cookie.js" > < / script >
< link href = "search/search.css" rel = "stylesheet" type = "text/css" / >
< script type = "text/javascript" src = "search/searchdata.js" > < / script >
< script type = "text/javascript" src = "search/search.js" > < / script >
< link href = "doxygen.css" rel = "stylesheet" type = "text/css" / >
< / head >
< body >
< div id = "top" > <!-- do not remove this div, it is closed by doxygen! -->
< div id = "titlearea" >
< table cellspacing = "0" cellpadding = "0" >
< tbody >
< tr id = "projectrow" >
< td id = "projectalign" >
< div id = "projectname" > MLX
< / div >
< / td >
< / tr >
< / tbody >
< / table >
< / div >
<!-- end header part -->
<!-- Generated by Doxygen 1.10.0 -->
< script type = "text/javascript" >
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699& dn=expat.txt MIT */
var searchBox = new SearchBox("searchBox", "search/",'.html');
/* @license-end */
< / script >
< script type = "text/javascript" src = "menudata.js" > < / script >
< script type = "text/javascript" src = "menu.js" > < / script >
< script type = "text/javascript" >
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699& dn=expat.txt MIT */
$(function() {
initMenu('',true,false,'search.php','Search');
$(function() { init_search(); });
});
/* @license-end */
< / script >
< div id = "main-nav" > < / div >
<!-- window showing the filter options -->
< div id = "MSearchSelectWindow"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
onkeydown="return searchBox.OnSearchSelectKey(event)">
< / div >
<!-- iframe showing the search results (closed by default) -->
< div id = "MSearchResultsWindow" >
< div id = "MSearchResults" >
< div class = "SRPage" >
< div id = "SRIndex" >
< div id = "SRResults" > < / div >
< div class = "SRStatus" id = "Loading" > Loading...< / div >
< div class = "SRStatus" id = "Searching" > Searching...< / div >
< div class = "SRStatus" id = "NoMatches" > No Matches< / div >
< / div >
< / div >
< / div >
< / div >
< div id = "nav-path" class = "navpath" >
< ul >
< li class = "navelem" > < a class = "el" href = "dir_938ab0ecf10b8b860ff766c820f665fd.html" > mlx< / a > < / li > < li class = "navelem" > < a class = "el" href = "dir_1d446c9bd3c99228254c9484e0bc5c06.html" > backend< / a > < / li > < li class = "navelem" > < a class = "el" href = "dir_d0c977ea65824390717cdb7efc36c157.html" > metal< / a > < / li > < / ul >
< / div >
< / div > <!-- top -->
< div class = "header" >
< div class = "summary" >
2024-08-11 00:24:35 +08:00
< a href = "#namespaces" > Namespaces< / a > |
< a href = "#func-members" > Functions< / a > < / div >
2024-06-07 11:28:06 +08:00
< div class = "headertitle" > < div class = "title" > utils.h File Reference< / div > < / div >
< / div > <!-- header -->
< div class = "contents" >
< div class = "textblock" > < code > #include " < a class = "el" href = "array_8h_source.html" > mlx/array.h< / a > " < / code > < br / >
< code > #include " < a class = "el" href = "backend_2metal_2device_8h_source.html" > mlx/backend/metal/device.h< / a > " < / code > < br / >
< code > #include " < a class = "el" href = "primitives_8h_source.html" > mlx/primitives.h< / a > " < / code > < br / >
< / div >
< p > < a href = "backend_2metal_2utils_8h_source.html" > Go to the source code of this file.< / a > < / p >
< table class = "memberdecls" >
< tr class = "heading" > < td colspan = "2" > < h2 class = "groupheader" > < a id = "namespaces" name = "namespaces" > < / a >
Namespaces< / h2 > < / td > < / tr >
< tr class = "memitem:namespacemlx" id = "r_namespacemlx" > < td class = "memItemLeft" align = "right" valign = "top" > namespace   < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "namespacemlx.html" > mlx< / a > < / td > < / tr >
< tr class = "separator:" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:namespacemlx_1_1core" id = "r_namespacemlx_1_1core" > < td class = "memItemLeft" align = "right" valign = "top" > namespace   < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "namespacemlx_1_1core.html" > mlx::core< / a > < / td > < / tr >
< tr class = "separator:" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
2024-08-11 00:24:35 +08:00
< / table > < table class = "memberdecls" >
< tr class = "heading" > < td colspan = "2" > < h2 class = "groupheader" > < a id = "func-members" name = "func-members" > < / a >
Functions< / h2 > < / td > < / tr >
< tr class = "memitem:a62340bbaa8b216539688a60adcb568bf" id = "r_a62340bbaa8b216539688a60adcb568bf" > < td class = "memTemplParams" colspan = "2" > template< typename T > < / td > < / tr >
< tr class = "memitem:a62340bbaa8b216539688a60adcb568bf" > < td class = "memTemplItemLeft" align = "right" valign = "top" > void  < / td > < td class = "memTemplItemRight" valign = "bottom" > < a class = "el" href = "namespacemlx_1_1core.html#a62340bbaa8b216539688a60adcb568bf" > mlx::core::set_vector_bytes< / a > (< a class = "el" href = "structmlx_1_1core_1_1metal_1_1_command_encoder.html" > CommandEncoder< / a > & enc, const std::vector< T > & vec, size_t nelems, int idx)< / td > < / tr >
< tr class = "separator:a62340bbaa8b216539688a60adcb568bf" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:ae309cb543dfb0239cfccc53a8ad0408e" id = "r_ae309cb543dfb0239cfccc53a8ad0408e" > < td class = "memTemplParams" colspan = "2" > template< typename T > < / td > < / tr >
< tr class = "memitem:ae309cb543dfb0239cfccc53a8ad0408e" > < td class = "memTemplItemLeft" align = "right" valign = "top" > void  < / td > < td class = "memTemplItemRight" valign = "bottom" > < a class = "el" href = "namespacemlx_1_1core.html#ae309cb543dfb0239cfccc53a8ad0408e" > mlx::core::set_vector_bytes< / a > (< a class = "el" href = "structmlx_1_1core_1_1metal_1_1_command_encoder.html" > CommandEncoder< / a > & enc, const std::vector< T > & vec, int idx)< / td > < / tr >
< tr class = "separator:ae309cb543dfb0239cfccc53a8ad0408e" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:af1fdfdaa5644394362e6baba30701bae" id = "r_af1fdfdaa5644394362e6baba30701bae" > < td class = "memItemLeft" align = "right" valign = "top" > std::string  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "namespacemlx_1_1core.html#af1fdfdaa5644394362e6baba30701bae" > mlx::core::type_to_name< / a > (const < a class = "el" href = "classmlx_1_1core_1_1array.html" > array< / a > & a)< / td > < / tr >
< tr class = "separator:af1fdfdaa5644394362e6baba30701bae" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a7b3f872f6046bdd4d429ee1f1c31cd40" id = "r_a7b3f872f6046bdd4d429ee1f1c31cd40" > < td class = "memItemLeft" align = "right" valign = "top" > MTL::Size  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "namespacemlx_1_1core.html#a7b3f872f6046bdd4d429ee1f1c31cd40" > mlx::core::get_block_dims< / a > (int dim0, int dim1, int dim2)< / td > < / tr >
< tr class = "separator:a7b3f872f6046bdd4d429ee1f1c31cd40" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a8dc169474a51a1f4f761d5752819bd7c" id = "r_a8dc169474a51a1f4f761d5752819bd7c" > < td class = "memItemLeft" align = "right" valign = "top" > MTL::Size  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "namespacemlx_1_1core.html#a8dc169474a51a1f4f761d5752819bd7c" > mlx::core::get_2d_grid_dims< / a > (const std::vector< int > & shape, const std::vector< size_t > & strides)< / td > < / tr >
< tr class = "separator:a8dc169474a51a1f4f761d5752819bd7c" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:aed148d95e7b5221f1312473deded0d27" id = "r_aed148d95e7b5221f1312473deded0d27" > < td class = "memItemLeft" align = "right" valign = "top" > NS::String *  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "namespacemlx_1_1core.html#aed148d95e7b5221f1312473deded0d27" > mlx::core::make_string< / a > (std::ostringstream & os)< / td > < / tr >
< tr class = "separator:aed148d95e7b5221f1312473deded0d27" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a79817d2432e782e596c9c49a08b93be2" id = "r_a79817d2432e782e596c9c49a08b93be2" > < td class = "memItemLeft" align = "right" valign = "top" > void  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "namespacemlx_1_1core.html#a79817d2432e782e596c9c49a08b93be2" > mlx::core::debug_set_stream_queue_label< / a > (MTL::CommandQueue *queue, int index)< / td > < / tr >
< tr class = "separator:a79817d2432e782e596c9c49a08b93be2" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a489e45b3a5cd8b46e8ea56b9132eb230" id = "r_a489e45b3a5cd8b46e8ea56b9132eb230" > < td class = "memItemLeft" align = "right" valign = "top" > void  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "namespacemlx_1_1core.html#a489e45b3a5cd8b46e8ea56b9132eb230" > mlx::core::debug_set_primitive_buffer_label< / a > (MTL::CommandBuffer *command_buffer, < a class = "el" href = "classmlx_1_1core_1_1_primitive.html" > Primitive< / a > & primitive)< / td > < / tr >
< tr class = "separator:a489e45b3a5cd8b46e8ea56b9132eb230" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:ad4be35b310a252edd80d9cf04f094a60" id = "r_ad4be35b310a252edd80d9cf04f094a60" > < td class = "memItemLeft" align = "right" valign = "top" > std::string  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "namespacemlx_1_1core.html#ad4be35b310a252edd80d9cf04f094a60" > mlx::core::get_primitive_string< / a > (< a class = "el" href = "classmlx_1_1core_1_1_primitive.html" > Primitive< / a > *primitive)< / td > < / tr >
< tr class = "separator:ad4be35b310a252edd80d9cf04f094a60" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
2024-06-07 11:28:06 +08:00
< / table >
< / div > <!-- contents -->
<!-- start footer part -->
< hr class = "footer" / > < address class = "footer" > < small >
Generated by  < a href = "https://www.doxygen.org/index.html" > < img class = "footer" src = "doxygen.svg" width = "104" height = "31" alt = "doxygen" / > < / a > 1.10.0
< / small > < / address >
< / body >
< / html >