Skip to content

Commit

Permalink
Merge branch 'master' into avoid-memory-leak-thread-local
Browse files Browse the repository at this point in the history
  • Loading branch information
liblit authored Sep 6, 2023
2 parents ce64a44 + e8967ec commit 73ae04d
Show file tree
Hide file tree
Showing 10 changed files with 27 additions and 9 deletions.
2 changes: 2 additions & 0 deletions build-logic/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
@file:Suppress("UnstableApiUsage")

import com.diffplug.spotless.LineEnding.PLATFORM_NATIVE

plugins {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,13 @@ abstract class VerifiedDownload : DefaultTask() {

// plugin-provided extension for downloading a resource from some URL
@Internal
@Suppress("LeakingThis")
val downloadExtension: DownloadExtension =
project.objects.newInstance(DownloadExtension::class.java, this)

// plugin-provided extension for verifying that a file has the expected checksum
@Internal
@Suppress("LeakingThis")
val verifyExtension: VerifyExtension =
project.objects.newInstance(VerifyExtension::class.java, this)

Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
@file:Suppress("UnstableApiUsage")

package com.ibm.wala.gradle

// Build configuration for subprojects that include Java source code.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
@file:Suppress("UnstableApiUsage")

package com.ibm.wala.gradle

plugins {
Expand Down Expand Up @@ -121,9 +123,9 @@ val mavenPublication =
}
}

val repositories = publishing.repositories
val repositories: RepositoryHandler = publishing.repositories

val mavenRepository =
val mavenRepository: MavenArtifactRepository =
repositories.maven {
url =
uri(
Expand Down
2 changes: 2 additions & 0 deletions cast/java/ecj/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
@file:Suppress("UnstableApiUsage")

plugins {
application
id("com.ibm.wala.gradle.eclipse-maven-central")
Expand Down
2 changes: 2 additions & 0 deletions cast/java/test/data/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
@file:Suppress("UnstableApiUsage")

import com.ibm.wala.gradle.VerifiedDownload
import java.net.URI
import net.ltgt.gradle.errorprone.errorprone
Expand Down
2 changes: 2 additions & 0 deletions cast/js/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
@file:Suppress("UnstableApiUsage")

import com.ibm.wala.gradle.CreatePackageList
import com.ibm.wala.gradle.VerifiedDownload
import java.net.URI
Expand Down
2 changes: 2 additions & 0 deletions cast/js/nodejs/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
@file:Suppress("UnstableApiUsage")

import com.ibm.wala.gradle.VerifiedDownload
import java.net.URI

Expand Down
2 changes: 2 additions & 0 deletions core/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
@file:Suppress("UnstableApiUsage")

import com.ibm.wala.gradle.CompileKawaScheme
import com.ibm.wala.gradle.JavaCompileUsingEcj
import com.ibm.wala.gradle.VerifiedDownload
Expand Down
14 changes: 7 additions & 7 deletions summarize-time-trials
Original file line number Diff line number Diff line change
Expand Up @@ -36,14 +36,14 @@ def main():

# print slowest individual tests, showing only those in the 95% percentile
# or higher (slower)
rankedTimes = pandas.DataFrame(times)
rankedTimes['percentRank'] = times.rank(pct=True)
elapsedTimes = rankedTimes['elapsedTime']
rankedTimes['fractionOfTotal'] = elapsedTimes / elapsedTimes.sum()
isSlow = rankedTimes['percentRank'] >= .95
slowestTests = rankedTimes[isSlow][::-1]
ranked_times = pandas.DataFrame(times)
ranked_times['percentRank'] = times.rank(pct=True)
elapsed_times = ranked_times['elapsedTime']
ranked_times['fractionOfTotal'] = elapsed_times / elapsed_times.sum()
is_slow = ranked_times['percentRank'] >= .95
slowest_tests = ranked_times[is_slow][::-1]
print('Slowest individual tests:')
print(slowestTests.to_string(formatters={'percentRank': '{:.1%}'.format}))
print(slowest_tests.to_string(formatters={'percentRank': '{:.1%}'.format}))


if __name__ == '__main__':
Expand Down

0 comments on commit 73ae04d

Please sign in to comment.