Skip to content

Commit

Permalink
Merge commit '6cf7fe4a9a715bcdf3f4913753109e22dfc9940b' into HEAD
Browse files Browse the repository at this point in the history
  • Loading branch information
mgehre-amd committed Jun 14, 2023
2 parents 20fa0e8 + 6cf7fe4 commit 3663896
Show file tree
Hide file tree
Showing 10,144 changed files with 861,889 additions and 565,113 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
9 changes: 9 additions & 0 deletions .git-blame-ignore-revs
Original file line number Diff line number Diff line change
Expand Up @@ -46,3 +46,12 @@ d8f0e6caa91e230a486c948ab643174e40bdf215

# [libc++][NFC] clang-format <__config>
ac251726f84d5b7e6533a2e3712920184435b61b

# Python black reformatting, by subdir. NFC
b71edfaa4ec3c998aadb35255ce2f60bba2940b0
f84bac329ba6c9f0c022bcf77237e912362e247a
dd3c26a045c081620375a878159f536758baba6e
7bfaa0f09d0564f315ea778023b34b8a113ec740
f98ee40f4b5d7474fc67e82824bf6abbaedb7b1c
2238dcc39358353cac21df75c3c3286ab20b8f53
f9008e6366c2496b1ca1785b891d5578174ad63e
5 changes: 0 additions & 5 deletions .github/PULL_REQUEST_TEMPLATE.md

This file was deleted.

2 changes: 1 addition & 1 deletion .github/workflows/release-tasks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
- name: Install Dependencies
run: |
sudo apt-get update \
sudo apt-get update
sudo apt-get install -y \
doxygen \
graphviz \
Expand Down
5 changes: 5 additions & 0 deletions .github/workflows/repo-lockdown.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@ name: 'Repo Lockdown'
on:
pull_request_target:
types: opened
paths-ignore:
- 'libcxx/**'
- 'libcxxabi/**'
- 'libunwind/**'
- 'runtimes/**'

permissions:
pull-requests: write
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/version-check.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@


def get_version_from_tag(tag):
m = re.match('llvmorg-([0-9]+)\.([0-9]+)\.([0-9]+)(-rc[0-9]+)?$', tag)
m = re.match("llvmorg-([0-9]+)\.([0-9]+)\.([0-9]+)(-rc[0-9]+)?$", tag)
if m:
if m.lastindex == 4:
# We have an rc tag.
return m.group(1,2,3)
return m.group(1, 2, 3)
# We have a final release tag.
return (m.group(1), m.group(2), str(int(m.group(3)) + 1))

m = re.match('llvmorg-([0-9]+)-init', tag)
m = re.match("llvmorg-([0-9]+)-init", tag)
if m:
return (m.group(1), "0", "0")

Expand All @@ -25,8 +25,8 @@ def get_version_from_tag(tag):

repo = Repo()

tag = repo.git.describe(tags = True, abbrev=0)
expected_version = '.'.join(get_version_from_tag(tag))
tag = repo.git.describe(tags=True, abbrev=0)
expected_version = ".".join(get_version_from_tag(tag))

if version != expected_version:
print("error: Expected version", expected_version, "but found version", version)
Expand Down
8 changes: 7 additions & 1 deletion bolt/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,10 @@ endif()

if (BOLT_ENABLE_RUNTIME)
message(STATUS "Building BOLT runtime libraries for X86")
set(extra_args "")
if(CMAKE_SYSROOT)
list(APPEND extra_args -DCMAKE_SYSROOT=${CMAKE_SYSROOT})
endif()
ExternalProject_Add(bolt_rt
SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/runtime"
STAMP_DIR ${CMAKE_CURRENT_BINARY_DIR}/bolt_rt-stamps
Expand All @@ -92,8 +96,10 @@ if (BOLT_ENABLE_RUNTIME)
-DCMAKE_CXX_COMPILER=${CMAKE_CXX_COMPILER}
-DCMAKE_BUILD_TYPE=Release
-DCMAKE_MAKE_PROGRAM=${CMAKE_MAKE_PROGRAM}
-DCMAKE_INSTALL_PREFIX=${LLVM_BINARY_DIR}
-DLLVM_LIBDIR_SUFFIX=${LLVM_LIBDIR_SUFFIX}
-DLLVM_LIBRARY_DIR=${LLVM_LIBRARY_DIR}
${extra_args}
INSTALL_COMMAND ""
BUILD_ALWAYS True
)
install(CODE "execute_process\(COMMAND \${CMAKE_COMMAND} -DCMAKE_INSTALL_PREFIX=\${CMAKE_INSTALL_PREFIX} -P ${CMAKE_CURRENT_BINARY_DIR}/bolt_rt-bins/cmake_install.cmake \)"
Expand Down
126 changes: 63 additions & 63 deletions bolt/docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,203 +16,197 @@
# If extensions (or modules to document with autodoc) are in another directory,
# add these directories to sys.path here. If the directory is relative to the
# documentation root, use os.path.abspath to make it absolute, like shown here.
#sys.path.insert(0, os.path.abspath('.'))
# sys.path.insert(0, os.path.abspath('.'))

# -- General configuration -----------------------------------------------------

# If your documentation needs a minimal Sphinx version, state it here.
#needs_sphinx = '1.0'
# needs_sphinx = '1.0'

# Add any Sphinx extension module names here, as strings. They can be extensions
# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
extensions = ['sphinx.ext.intersphinx', 'sphinx.ext.todo']
extensions = ["sphinx.ext.intersphinx", "sphinx.ext.todo"]

# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']
templates_path = ["_templates"]

# The suffix of source filenames.
source_suffix = '.rst'
source_suffix = ".rst"

# The encoding of source files.
#source_encoding = 'utf-8-sig'
# source_encoding = 'utf-8-sig'

# The master toctree document.
master_doc = 'index'
master_doc = "index"

# General information about the project.
project = u'BOLT'
copyright = u'2015-%d, BOLT team' % date.today().year
project = "BOLT"
copyright = "2015-%d, BOLT team" % date.today().year

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
#language = None
# language = None

# There are two options for replacing |today|: either, you set today to some
# non-false value, then it is used:
#today = ''
# today = ''
# Else, today_fmt is used as the format for a strftime call.
today_fmt = '%Y-%m-%d'
today_fmt = "%Y-%m-%d"

# List of patterns, relative to source directory, that match files and
# directories to ignore when looking for source files.
exclude_patterns = ['_build']
exclude_patterns = ["_build"]

# The reST default role (used for this markup: `text`) to use for all documents.
#default_role = None
# default_role = None

# If true, '()' will be appended to :func: etc. cross-reference text.
#add_function_parentheses = True
# add_function_parentheses = True

# If true, the current module name will be prepended to all description
# unit titles (such as .. function::).
#add_module_names = True
# add_module_names = True

# If true, sectionauthor and moduleauthor directives will be shown in the
# output. They are ignored by default.
show_authors = True

# The name of the Pygments (syntax highlighting) style to use.
pygments_style = 'friendly'
pygments_style = "friendly"

# A list of ignored prefixes for module index sorting.
#modindex_common_prefix = []
# modindex_common_prefix = []


# -- Options for HTML output ---------------------------------------------------

# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
html_theme = 'haiku'
html_theme = "haiku"

# Theme options are theme-specific and customize the look and feel of a theme
# further. For a list of options available for each theme, see the
# documentation.
#html_theme_options = {}
# html_theme_options = {}

# Add any paths that contain custom themes here, relative to this directory.
html_theme_path = ["."]

# The name for this set of Sphinx documents. If None, it defaults to
# "<project> v<release> documentation".
#html_title = None
# html_title = None

# A shorter title for the navigation bar. Default is the same as html_title.
#html_short_title = None
# html_short_title = None

# The name of an image file (relative to this directory) to place at the top
# of the sidebar.
#html_logo = None
# html_logo = None

# If given, this must be the name of an image file (path relative to the
# configuration directory) that is the favicon of the docs. Modern browsers use
# this as icon for tabs, windows and bookmarks. It should be a Windows-style
# icon file (.ico), which is 16x16 or 32x32 pixels large. Default: None. The
# image file will be copied to the _static directory of the output HTML, but
# only if the file does not already exist there.
html_favicon = '_static/favicon.ico'
html_favicon = "_static/favicon.ico"

# Add any paths that contain custom static files (such as style sheets) here,
# relative to this directory. They are copied after the builtin static files,
# so a file named "default.css" will overwrite the builtin "default.css".
html_static_path = ['_static']
html_static_path = ["_static"]

# If not '', a 'Last updated on:' timestamp is inserted at every page bottom,
# using the given strftime format.
html_last_updated_fmt = '%Y-%m-%d'
html_last_updated_fmt = "%Y-%m-%d"

# If true, SmartyPants will be used to convert quotes and dashes to
# typographically correct entities.
#html_use_smartypants = True
# html_use_smartypants = True

# Custom sidebar templates, maps document names to template names.
html_sidebars = {'index': ['indexsidebar.html']}
html_sidebars = {"index": ["indexsidebar.html"]}

# Additional templates that should be rendered to pages, maps page names to
# template names.
# html_additional_pages = {'index': 'index.html'}

# If false, no module index is generated.
#html_domain_indices = True
# html_domain_indices = True

# If false, no index is generated.
#html_use_index = True
# html_use_index = True

# If true, the index is split into individual pages for each letter.
#html_split_index = False
# html_split_index = False

# If true, links to the reST sources are added to the pages.
html_show_sourcelink = True

# If true, "Created using Sphinx" is shown in the HTML footer. Default is True.
#html_show_sphinx = True
# html_show_sphinx = True

# If true, "(C) Copyright ..." is shown in the HTML footer. Default is True.
#html_show_copyright = True
# html_show_copyright = True

# If true, an OpenSearch description file will be output, and all pages will
# contain a <link> tag referring to it. The value of this option must be the
# base URL from which the finished HTML is served.
#html_use_opensearch = ''
# html_use_opensearch = ''

# This is the file name suffix for HTML files (e.g. ".xhtml").
#html_file_suffix = None
# html_file_suffix = None

# Output file base name for HTML help builder.
htmlhelp_basename = 'boltdoc'
htmlhelp_basename = "boltdoc"


# -- Options for LaTeX output --------------------------------------------------

latex_elements = {
# The paper size ('letterpaper' or 'a4paper').
#'papersize': 'letterpaper',

# The font size ('10pt', '11pt' or '12pt').
#'pointsize': '10pt',

# Additional stuff for the LaTeX preamble.
#'preamble': '',
# The paper size ('letterpaper' or 'a4paper').
#'papersize': 'letterpaper',
# The font size ('10pt', '11pt' or '12pt').
#'pointsize': '10pt',
# Additional stuff for the LaTeX preamble.
#'preamble': '',
}

# Grouping the document tree into LaTeX files. List of tuples
# (source start file, target name, title, author, documentclass [howto/manual]).
latex_documents = [
('contents', 'bolt.tex', u'BOLT Documentation',
u'LLVM project', 'manual'),
("contents", "bolt.tex", "BOLT Documentation", "LLVM project", "manual"),
]

# The name of an image file (relative to this directory) to place at the top of
# the title page.
#latex_logo = None
# latex_logo = None

# For "manual" documents, if this is true, then toplevel headings are parts,
# not chapters.
#latex_use_parts = False
# latex_use_parts = False

# If true, show page references after internal links.
#latex_show_pagerefs = False
# latex_show_pagerefs = False

# If true, show URL addresses after external links.
#latex_show_urls = False
# latex_show_urls = False

# Documents to append as an appendix to all manuals.
#latex_appendices = []
# latex_appendices = []

# If false, no module index is generated.
#latex_domain_indices = True
# latex_domain_indices = True


# -- Options for manual page output --------------------------------------------

# One entry per manual page. List of tuples
# (source start file, name, description, authors, manual section).
man_pages = [
('contents', 'bolt', u'BOLT Documentation',
[u'LLVM project'], 1)
]
man_pages = [("contents", "bolt", "BOLT Documentation", ["LLVM project"], 1)]

# If true, show URL addresses after external links.
#man_show_urls = False
# man_show_urls = False


# -- Options for Texinfo output ------------------------------------------------
Expand All @@ -221,19 +215,25 @@
# (source start file, target name, title, author,
# dir menu entry, description, category)
texinfo_documents = [
('contents', 'BOLT', u'BOLT Documentation',
u'LLVM project', 'BOLT', 'Binary Optimization and Layout Tool',
'Miscellaneous'),
(
"contents",
"BOLT",
"BOLT Documentation",
"LLVM project",
"BOLT",
"Binary Optimization and Layout Tool",
"Miscellaneous",
),
]

# Documents to append as an appendix to all manuals.
#texinfo_appendices = []
# texinfo_appendices = []

# If false, no module index is generated.
#texinfo_domain_indices = True
# texinfo_domain_indices = True

# How to display URL addresses: 'footnote', 'no', or 'inline'.
#texinfo_show_urls = 'footnote'
# texinfo_show_urls = 'footnote'


# FIXME: Define intersphinx configuration.
Expand Down
10 changes: 10 additions & 0 deletions bolt/include/bolt/Core/BinaryFunction.h
Original file line number Diff line number Diff line change
Expand Up @@ -1757,6 +1757,16 @@ class BinaryFunction {
return ParentFragments.contains(&Other);
}

/// Returns if this function is a parent of \p Other function.
bool isParentOf(const BinaryFunction &Other) const {
return llvm::is_contained(Fragments, &Other);
}

/// Returns if this function is a parent or child of \p Other function.
bool isParentOrChildOf(const BinaryFunction &Other) const {
return isChildOf(Other) || isParentOf(Other);
}

/// Set the profile data for the number of times the function was called.
BinaryFunction &setExecutionCount(uint64_t Count) {
ExecutionCount = Count;
Expand Down
Loading

0 comments on commit 3663896

Please sign in to comment.