Optimize Code for Performance
Identify performance bottlenecks and improve code for speed, memory usage, and scalability.
Prompt template
- Format
- Text Parameterized
- Inputs
- code_and_context (code, text) · Required
- Outputs
- performance_analysis_and_optimized_code (text, code)
Think like a performance engineer optimizing this code. Optimize for speed, memory usage, and scalability. Find bottlenecks, inefficient logic, and unnecessary rendering.
Provide:
- Performance issues
- Optimization strategies
- Improved code
Code and relevant performance context:
${code-and-context}
Replace the ${…} placeholders with your values
before using this prompt. See parameters
and defaults below
Parameters
Replace each placeholder with your own value, or use its default when one is provided
${code-and-context}
code-and-context
Required
What you'll create
A performance review identifies inefficient logic, bottlenecks and unnecessary rendering. It provides optimization strategies and revised code in the supplied performance context.
Frequently asked questions
Which performance dimensions are considered?
The requested analysis covers speed, memory usage and scalability.
Comments
Tried this prompt? Share what you made, compare results, or ask a question