@@ -1349,8 +1349,7 @@ private CcCompilationOutputs createCcCompileActions(Consumer<String> errorReport
1349
1349
if (!sourceArtifact .isTreeArtifact ()) {
1350
1350
switch (source .getType ()) {
1351
1351
case HEADER :
1352
- createHeaderAction (
1353
- sourceLabel , outputName , result , builder , isGenerateDotdFile (sourceArtifact ));
1352
+ createHeaderAction (sourceLabel , outputName , result , builder );
1354
1353
break ;
1355
1354
default :
1356
1355
createSourceAction (
@@ -1372,8 +1371,7 @@ private CcCompilationOutputs createCcCompileActions(Consumer<String> errorReport
1372
1371
// output (since it isn't generating a native object with debug
1373
1372
// info). In that case the LtoBackendAction will generate the dwo.
1374
1373
ccToolchain .shouldCreatePerObjectDebugInfo (featureConfiguration , cppConfiguration ),
1375
- bitcodeOutput ,
1376
- isGenerateDotdFile (sourceArtifact ));
1374
+ bitcodeOutput );
1377
1375
break ;
1378
1376
}
1379
1377
} else {
@@ -1649,8 +1647,7 @@ private void createModuleCodegenAction(
1649
1647
ruleErrorConsumer ,
1650
1648
label ,
1651
1649
ArtifactCategory .OBJECT_FILE ,
1652
- outputName ,
1653
- isGenerateDotdFile (module ));
1650
+ outputName );
1654
1651
PathFragment ccRelativeName = module .getRootRelativePath ();
1655
1652
1656
1653
String gcnoFileName =
@@ -1700,18 +1697,11 @@ private void createModuleCodegenAction(
1700
1697
}
1701
1698
}
1702
1699
1703
- /** Returns true if Dotd file should be generated. */
1704
- private boolean isGenerateDotdFile (Artifact sourceArtifact ) {
1705
- return CppFileTypes .headerDiscoveryRequired (sourceArtifact )
1706
- && !featureConfiguration .isEnabled (CppRuleClasses .PARSE_SHOWINCLUDES );
1707
- }
1708
-
1709
1700
private void createHeaderAction (
1710
1701
Label sourceLabel ,
1711
1702
String outputName ,
1712
1703
CcCompilationOutputs .Builder result ,
1713
- CppCompileActionBuilder builder ,
1714
- boolean generateDotd )
1704
+ CppCompileActionBuilder builder )
1715
1705
throws RuleErrorException {
1716
1706
String outputNameBase =
1717
1707
CppHelper .getArtifactNameForCategory (
@@ -1723,8 +1713,7 @@ private void createHeaderAction(
1723
1713
ruleErrorConsumer ,
1724
1714
label ,
1725
1715
ArtifactCategory .PROCESSED_HEADER ,
1726
- outputNameBase ,
1727
- generateDotd )
1716
+ outputNameBase )
1728
1717
// If we generate pic actions, we prefer the header actions to use the pic artifacts.
1729
1718
.setPicMode (generatePicAction );
1730
1719
builder .setVariables (
@@ -1768,8 +1757,7 @@ private Collection<Artifact> createModuleAction(
1768
1757
/* addObject= */ false ,
1769
1758
/* enableCoverage= */ false ,
1770
1759
/* generateDwo= */ false ,
1771
- /* bitcodeOutput= */ false ,
1772
- isGenerateDotdFile (moduleMapArtifact ));
1760
+ /* bitcodeOutput= */ false );
1773
1761
}
1774
1762
1775
1763
private Collection <Artifact > createSourceAction (
@@ -1783,8 +1771,7 @@ private Collection<Artifact> createSourceAction(
1783
1771
boolean addObject ,
1784
1772
boolean enableCoverage ,
1785
1773
boolean generateDwo ,
1786
- boolean bitcodeOutput ,
1787
- boolean generateDotd )
1774
+ boolean bitcodeOutput )
1788
1775
throws RuleErrorException {
1789
1776
ImmutableList .Builder <Artifact > directOutputs = new ImmutableList .Builder <>();
1790
1777
PathFragment ccRelativeName = sourceArtifact .getRootRelativePath ();
@@ -1795,8 +1782,7 @@ private Collection<Artifact> createSourceAction(
1795
1782
String picOutputBase =
1796
1783
CppHelper .getArtifactNameForCategory (
1797
1784
ruleErrorConsumer , ccToolchain , ArtifactCategory .PIC_FILE , outputName );
1798
- CppCompileActionBuilder picBuilder =
1799
- copyAsPicBuilder (builder , picOutputBase , outputCategory , generateDotd );
1785
+ CppCompileActionBuilder picBuilder = copyAsPicBuilder (builder , picOutputBase , outputCategory );
1800
1786
String gcnoFileName =
1801
1787
CppHelper .getArtifactNameForCategory (
1802
1788
ruleErrorConsumer , ccToolchain , ArtifactCategory .COVERAGE_DATA_FILE , picOutputBase );
@@ -1830,7 +1816,6 @@ private Collection<Artifact> createSourceAction(
1830
1816
outputName ,
1831
1817
picBuilder ,
1832
1818
/* usePic= */ true ,
1833
- /* generateDotd= */ generateDotd ,
1834
1819
ccRelativeName ));
1835
1820
1836
1821
picBuilder .setGcnoFile (gcnoFile );
@@ -1865,12 +1850,7 @@ private Collection<Artifact> createSourceAction(
1865
1850
ruleErrorConsumer , ccToolchain , outputCategory , outputName ),
1866
1851
configuration );
1867
1852
builder .setOutputs (
1868
- actionConstructionContext ,
1869
- ruleErrorConsumer ,
1870
- label ,
1871
- outputCategory ,
1872
- outputName ,
1873
- generateDotd );
1853
+ actionConstructionContext , ruleErrorConsumer , label , outputCategory , outputName );
1874
1854
String gcnoFileName =
1875
1855
CppHelper .getArtifactNameForCategory (
1876
1856
ruleErrorConsumer , ccToolchain , ArtifactCategory .COVERAGE_DATA_FILE , outputName );
@@ -1905,7 +1885,6 @@ private Collection<Artifact> createSourceAction(
1905
1885
outputName ,
1906
1886
builder ,
1907
1887
/* usePic= */ false ,
1908
- generateDotd ,
1909
1888
ccRelativeName ));
1910
1889
1911
1890
builder .setGcnoFile (gcnoFile );
@@ -1938,21 +1917,13 @@ private Collection<Artifact> createSourceAction(
1938
1917
* changing output and dotd file names.
1939
1918
*/
1940
1919
private CppCompileActionBuilder copyAsPicBuilder (
1941
- CppCompileActionBuilder builder ,
1942
- String outputName ,
1943
- ArtifactCategory outputCategory ,
1944
- boolean generateDotd )
1920
+ CppCompileActionBuilder builder , String outputName , ArtifactCategory outputCategory )
1945
1921
throws RuleErrorException {
1946
1922
CppCompileActionBuilder picBuilder = new CppCompileActionBuilder (builder );
1947
1923
picBuilder
1948
1924
.setPicMode (true )
1949
1925
.setOutputs (
1950
- actionConstructionContext ,
1951
- ruleErrorConsumer ,
1952
- label ,
1953
- outputCategory ,
1954
- outputName ,
1955
- generateDotd );
1926
+ actionConstructionContext , ruleErrorConsumer , label , outputCategory , outputName );
1956
1927
1957
1928
return picBuilder ;
1958
1929
}
@@ -2029,7 +2000,6 @@ private ImmutableList<Artifact> createTempsActions(
2029
2000
String outputName ,
2030
2001
CppCompileActionBuilder builder ,
2031
2002
boolean usePic ,
2032
- boolean generateDotd ,
2033
2003
PathFragment ccRelativeName )
2034
2004
throws RuleErrorException {
2035
2005
if (!cppConfiguration .getSaveTemps ()) {
@@ -2051,12 +2021,7 @@ private ImmutableList<Artifact> createTempsActions(
2051
2021
2052
2022
CppCompileActionBuilder dBuilder = new CppCompileActionBuilder (builder );
2053
2023
dBuilder .setOutputs (
2054
- actionConstructionContext ,
2055
- ruleErrorConsumer ,
2056
- label ,
2057
- category ,
2058
- outputArtifactNameBase ,
2059
- generateDotd );
2024
+ actionConstructionContext , ruleErrorConsumer , label , category , outputArtifactNameBase );
2060
2025
dBuilder .setVariables (
2061
2026
setupCompileBuildVariables (
2062
2027
dBuilder ,
@@ -2082,8 +2047,7 @@ private ImmutableList<Artifact> createTempsActions(
2082
2047
ruleErrorConsumer ,
2083
2048
label ,
2084
2049
ArtifactCategory .GENERATED_ASSEMBLY ,
2085
- outputArtifactNameBase ,
2086
- generateDotd );
2050
+ outputArtifactNameBase );
2087
2051
sdBuilder .setVariables (
2088
2052
setupCompileBuildVariables (
2089
2053
sdBuilder ,
0 commit comments