<PAGE>   1
                                                                    EXHIBIT 10.7

[MARVELL LOGO]
                                                   MARVELL TECHNOLOGY GROUP LTD.
                            WAFER PURCHASE AGREEMENT


        THIS WAFER PURCHASE AGREEMENT (the "Agreement") is entered into as of
June 30, 1997 (the "Effective Date"), by and between MARVELL TECHNOLOGY GROUP,
LTD., a Bermuda corporation, having its principal place of business at Clarendon
House, 2 Churchill Street, Hamilton HM11, Bermuda ("MARVELL"), and TAIWAN
SEMICONDUCTOR MANUFACTURING CORPORATION, a Taiwan corporation having its
principal place of business at No. 121, PARK AVE. 3, SBIP, Hsio-Chu, Taiwan,
R.O.C. ("TSMC").

RECITALS

        WHEREAS, MARVELL desires to have certain products of its design
manufactured by TSMC for sale by MARVELL; and

        WHEREAS, TSMC has the capability of manufacturing MARVELL's products and
has agreed to supply to MARVELL certain fabricated silicon wafers.

        THEREFORE, in consideration of the foregoing and covenants contained
below, the parties agree as follows:

Section 1. Definitions.

        1.1     "Acceptance Criteria" shall mean the electrical and visual
specifications described in Exhibit A to this Agreement.

        1.2     "TSMC Capacity Commitment" shall mean TSMC's commitment as set
forth in Section 3.2 below and Exhibit B attached hereto.

        1.3     "Process" shall mean TSMC's mixed mode, double and triple metal
logic processes used by TSMC according to this Agreement to manufacture one or
more of the Products or any equivalent process developed by TSMC that meets with
MARVELL's approval.

        1.4     "Product(s)" shall mean MARVELL's integrated circuits which it
requests TSMC to manufacture and provide in Wafer form.

        1.5     "Proprietary Information" shall mean information that the
disclosing party considers to be proprietary and/or confidential, including but
not limited to, trade secrets, discoveries, ideas, concepts, know-how,
techniques, designs, specifications, drawings, diagrams, data, computer
programs, business activities and operations, reports, studies and other
technical and business information.

        1.6     "Wafer(s)" shall mean silicon wafers manufactured by TSMC and
sold exclusively to MARVELL using the Process agreed to by the parties. Wafer
requirements shall be stated in six (6) inch equivalents; all Wafers shall be
six- (6-) inch or eight- (8-) inch silicon wafers, unless both parties mutually
agree otherwise.
<PAGE>   2
[MARVELL LOGO]                                     MARVELL TECHNOLOGY GROUP LTD.

Section 2. Process Technical Information.

     For each Process, TSMC shall provide MARVELL in writing with all technical
information that MARVELL reasonably requires to develop circuit simulation
models or data bases, or both. The information to be supplied by TSMC shall
include but not be limited to the following:

          (a)  detailed design rules;

          (b)  process flow outline;

          (c)  process parameter specifications;

          (d)  electric parameter specifications;

          (e)  quality control monitor flow;

          (f)  SPICE model parameters; and

          (g)  other information as shall be mutually agreed upon by both
               parties.

Section 3.  Wafer Capacity Commitment to MARVELL.

     3.1   Manufacturing. Upon MARVELL's orders therefor and subject to
qualification pursuant to Section 5 below, TSMC agrees to manufacture and sell
Products, and MARVELL agrees to purchase such Products from TSMC, on the terms
and conditions set forth herein. TSMC agrees to provide MARVELL access to TSMC
wafer fabs which give the best cost, efficiency and lowest defect density
available.

     3.2   TSMC Capacity Commitment. Effective immediately, TSMC shall reserve
for and allocate to MARVELL such minimum wafer manufacturing capacity as is set
forth on Exhibit B at the prices set forth in Section 6.

     3.3   Reject Wafer Protection. After stable yields have been achieved, the
parties shall agree, in good faith, on the average standard yield per wafer
sort. If TSMC produces any Wafers which yield twenty percent (20%) or less of
the average standard yield at wafer sort, then TSMC shall credit MARVELL for
the full price MARVELL paid for such Wafers. If TSMC produces any Wafers which
yield between twenty percent (20%) and eighty percent (80%) of the average
standard yield at wafer sort, then TSMC shall credit MARVELL for a pro-rata
portion of the full price MARVELL paid for such Wafers. If MARVELL requests
Wafers to replace those rejected, TSMC shall use reasonable best efforts to
replace such Wafers; in any event, TSMC will restart the lots within two weeks
of the rejection. In the event TSMC requests an RMA, MARVELL will use
reasonable commercial efforts to determine the cause of a low yield and work
with TSMC to provide a corrective action. Wafer sort will be done by TSMC at
TSMC or an agreed upon location.

                                      -2-



<PAGE>   3
[MARVELL LOGO]                                     MARVELL TECHNOLOGY GROUP LTD.

Section 4. Mask Tooling Sets.

        4.1 Mask Ownership. TSMC acknowledges and agrees that data base and mask
tooling sets are proprietary to MARVELL, and shall be and remain the property of
MARVELL, be treated as MARVELL's confidential materials, be used only for the
purpose of filling MARVELL's needs and for no other purpose, and shall at all
times contain MARVELL's trademark, mask work and copyright notices. TSMC is
responsible for replacing damaged or broken masks.

        4.2 Care and Confidentiality of Masks. TSMC agrees to exercise the same
degree of care in protecting the property of MARVELL mask tooling sets as is
exercised by TSMC for information which TSMC considers highly confidential and
proprietary to TSMC.

        4.3 Return of Masks. TSMC shall promptly return MARVELL's mask tooling
sets upon MARVELL's request in writing.

        4.4 Vendor Selection. TSMC and MARVELL shall jointly agree on mask
vendor selection.

Section 5. Qualification and Modification.

        5.1 Engineering Lots. MARVELL may order engineering lots where it seeks
the qualification of an update to a Product or a Product not previously
manufactured by TSMC, or seeks to otherwise improve functionality and yield, or
to make any other engineering changes. For purposes of this Agreement, an
engineering lot shall contain 12 Wafers. It shall be MARVELL's responsibility to
inform and provide TSMC with the specifications for the engineering changes to
be made to an engineering lot before production begins.

        5.2 Acceptance Criteria. As part of the completion of the qualification
process for each Product, the parties shall agree on the Acceptance Criteria to
be used for the acceptance of Wafers. Such Acceptance Criteria shall be reduced
to writing and attached to this Agreement as Exhibit A and shall constitute the
contractual standards according to which MARVELL shall conduct acceptance of the
Wafers.

        5.3 Successful Qualification. MARVELL shall notify TSMC as soon as is
practicable after delivery of prototype Wafers, of MARVELL's determination that
the prototype Wafers meet the Acceptance Criteria set forth in Exhibit A.

        5.4 Production Wafers Prior to Qualification. Although MARVELL does not
expect that production quantities of Wafers of a Product will be manufactured
prior to completion of the qualification process under Sections 5.1 through 5.3
above, MARVELL reserves the right to have TSMC manufacture production quantities
of such Wafers prior to qualification.

        5.5 Modifications After Qualifications.

            (a) Changes to Acceptance Criteria. If either MARVELL or TSMC
desires to make any changes to the Acceptance Criteria for any Product, it shall
notify the other party in


<PAGE>   4
[MARVELL LOGO]

                                                   MARVELL TECHNOLOGY GROUP LTD.

writing and negotiate the changes in good faith, including any changes in prices
required by such modifications.

                (b)     Changes to Process.

                        (i)     Changes to Process that TSMC Requests. If, after
qualification is completed successfully for any Product to be manufactured under
this Agreement, TSMC desires to make Process changes affecting the Product's
form, fit or function, TSMC shall request in writing for the permission to make
such changes. If the proposed changes are unacceptable to MARVELL, TSMC and
MARVELL will meet to discuss such proposed changes with the understanding that
should the change in any way affect the performance or yield of a MARVELL device
in a negative manner, TSMC will not make the change for a period of not less
than one year.

                        (ii)    Changes to Process that MARVELL Requests. If,
after Qualification is completed successfully for any product to be
manufactured under this Agreement, MARVELL desires to make a change to the
Process, MARVELL shall make a written request to TSMC. After reviewing the
requested changes, TSMC shall consider such request and, if appropriate, propose
a development and qualification plan and any associated charges. After
completion of the development, TSMC may propose a reasonable Wafer price change,
if any, associated with the Process change.

Section 6. Prices, Charges and Payments.

        6.1     Price. The price for Wafers shall be fixed every quarter in good
faith by the mutual agreement of both parties and set forth on Exhibit C
attached hereto; the price shall be based on the fair market value of such
Wafers at the time price is established.

        6.2     Hot Lots. Prices for engineering lots ordered by MARVELL to be
delivered in less than the normal cycle times determined pursuant to Section 9
below, if any, shall be mutually agreed upon by the parties in good faith.

        6.3     Payment Terms. Unless otherwise agreed upon by the parties,
payment terms shall be net due thirty (30) days after the receipt of TSMC's
invoice.

        6.4     Taxes. MARVELL shall be responsible for and shall pay any
present or future customs duties or sales, use, excise or other similar tax
applicable to the sale of goods covered by this Agreement or MARVELL shall
supply TSMC with a reasonably satisfactory tax exemption certificate.

Section 7. Rolling Forecasts.

        By the fifteenth working day of each month, MARVELL shall provide TSMC a
rolling forecast of its monthly volume requirement for the following twelve (12)
months for Wafers by Process manufactured by TSMC (the "Forecast"), the first
three (3) months of such Forecast being binding on both parties. The parties
hereby agree that the Forecast is subject to a plus or minus change of
thirty-three percent (33%) from the stated amounts for months 3 through 6 of


                                      -4-
<PAGE>   5
[MARVELL LOGO]                                     MARVELL TECHNOLOGY GROUP LTD.

the Forecast, and a plus or minus change of fifty percent (50%) from the stated
amounts for months 7 through 12 of the Forecast. In the event MARVELL requires
changes to the Forecast, TSMC will use reasonable efforts to consider such
changes and reach mutually agreeable changes in good faith.

       MARVELL'S forecasts shall constitute good faith estimates of MARVELL's
anticipated requirements for Wafers for the periods indicated based on current
market conditions (but, in the absence of a purchase order, shall not be a
commitment by MARVELL for purchase of Wafers, except as set forth in the
proceeding paragraph).

Section 8. Purchase Orders.
       8.1  Placement of Purchase Orders. Purchase orders ("Purchase Orders")
submitted by MARVELL shall be for a fixed quantity of Wafer lots (a production
wafer lot shall contain 24 wafers). TSMC shall accept the Purchase Order offer
by written acknowledgment of the Purchase Orders placed. The Purchase Order
shall be effective only upon TSMC's acknowledgement by written notice within
five (5) business days of receipt of the order; provided, however, if TSMC has
not rejected the Purchase Order within such five day period, the Purchase Order
will be deemed accepted. The terms and conditions of this Agreement shall
control all sales of Products hereunder, and any inconsistent terms or
conditions in any purchase order, acknowledgement, notice or similar document
shall be of no effect.

       8.2    Content of Purchase Orders. Each Purchase Order shall contain:

              (a)  Products to be purchased;

              (b)  quantities of Wafer lots for each Product;

              (c)  requested shipment date;

              (d)  destination and requested carriers, and

              (e)  confirmation of the price for each Wafer.

Section 9. Cycle Times.
       Cycle times, by Process for each Product, from TSMC's acceptance of
MARVELL's Purchase Order until delivery of the Product to MARVELL's selected
transportation carrier are set forth on Exhibit C attached hereto.

Section 10. Manufacturing Information.
       Upon MARVELL's written request, TSMC shall make available for review any
process control information including but not limited to: Process and electrical
test yield results, calibration schedules and parametric test results.

Section 11. Delivery of Orders
       11.1 Transfer of Ownership. Unless otherwise agreed to in writing between
the parties, TSMC shall deliver the Products to MARVELL F.O.B. TSMC Taiwan.
Title and risk of


                                      -5-
<PAGE>   6
[MARVELL LOGO]                                     MARVELL TECHNOLOGY GROUP LTD.

loss shall pass to MARVELL upon this delivery. TSMC shall package the Products
for secure shipment according to standard industrial manufacturing practices in
consideration of the method of shipment chosen.

      11.2  Partial Shipments. Partial shipments are allowed, so long as full
shipment of the appropriate quantities are made by the delivery dates specified
in the Purchase Order acknowledgment. Such partial shipments may be invoiced
individually or in combination with all the other partial shipments made for the
same Purchase Orders. Invoices for Wafers put on hold under Sections 6.4 and 6.5
above shall be treated as a partial shipment and paid according to the terms in
Section 6.7 above.

Section 12. Acceptance, Testing and Inspection.

      12.1  Notification of Acceptance. MARVELL shall accept all Wafers
delivered under this Agreement that meet the Acceptance Criteria and the minimum
good die yield thresholds established by the parties for such Wafers and shall
notify TSMC in writing, within forty-five (45) days following the delivery of
any Wafers, as to rejection thereof. If no notification indicating rejection is
received by TSMC within the above time period, then such Wafers shall be deemed
accepted.

      12.2  MARVELL Inspection of Product. MARVELL may inspect the Products and
carry out testing, prior to acceptance, at its own facilities, to determine if
the Products meet the Acceptance Criteria.

Section 13. Proprietary Information

      13.1  Restriction on Use and Disclosure of Proprietary Information. Both
parties agree to maintain each other's Proprietary Information in strict
confidence, now to make use thereof other than for the performance of this
Agreement, to release it only to the receiving party's employees who have a
reasonable need to know the same, and not to release or disclose it to any third
parties, without the prior written consent of the disclosing party. The
obligations set forth in this Section shall not apply to any information that:
(a) is now or hereafter in public domain or otherwise becomes available to the
public other than by breach of this Agreement by the receiving party, (b) has
been rightfully in the receiving party's possession prior to receipt from the
disclosing party, (c) is rightfully received by the receiving party from a third
party, (d) is independently developed by the receiving party, and (e) is
authorized by the disclosing party to be released or disclosed.

      13.2 Ownership. All Proprietary Information and any copies thereof shall
remain the property of the disclosing party, and no license or other rights is
granted or implied hereby The receiving party shall, upon the disclosing party's
request, return the original and all copies of tangible Proprietary Information.
Any masks generated by TSMC from MARVELL's database tapes shall be the property
of MARVELL and shall be immediately returned to MARVELL upon its request.

      13.3  Survival of Obligation. Obligations under this Section shall survive
any termination of this Agreement.

                                      -6-





<PAGE>   7
[MARVELL LOGO]                                     MARVELL TECHNOLOGY GROUP LTD.

Section 14. Warranty.

     14.1   Product Warranty. TSMC warrants that the Products delivered under
this Agreement shall be free from defects in material and workmanship under
normal use for a period of one (1) year from the date of shipment. If a Product
is mutually determined to be defective, then TSMC shall either repair, replace,
or credit MARVELL for such defective Products. Refunds or credits will be made
within ten (10) days and replacements products will be provided as soon as
practicable, but in no event longer than forty-five (45) days after their
return to TSMC. TSMC shall be responsible for all transportation costs
associated with MARVELL's exercise of this warranty coverage.

     14.2    Limitation on Warranty. THE FOREGOING WARRANTY SHALL BE EXCLUSIVE
AND IN LIEU OF ANY AND ALL OTHER WARRANTIES, EXPRESS, IMPLIED OR STATUTORY,
INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
A PARTICULAR PURPOSE, ALL OF WHICH ARE HEREBY EXPRESSLY DISCLAIMED.

Section 15. Intellectual Property.

     15.1   Indemnity. With respect to each party's respective proprietary
contribution to any Products provided, manufactured, sold or otherwise
transferred hereunder, such party agrees to defend, indemnify and hold harmless
the other party against any loss, costs, liability or expense arising out of or
resulting from any actions or claims brought against such other party to the
extent based upon a claim that such contribution infringes any patent, trade
secret or other intellectual property right of any third party (collectively,
"Third Party Rights"), and agrees to pay any settlements entered into or
damages awarded against such other party to the extent based upon such a claim;
provided, that the party seeking indemnification provides reasonably prompt
notice thereof and reasonable assistance in connection with the defense thereof
at the indemnifying party's expense, and allows the indemnifying party full
control of the defense and settlement thereof.

Section 16. Limitation of Liability.

     IN NO EVENT SHALL EITHER PARTY BE LIABLE FOR ANY INDIRECT, SPECIAL,
INCIDENTAL OR CONSEQUENTIAL DAMAGES (INCLUDING LOSS OF PROFITS AND LOSS OF USE)
RESULTING FROM, ARISING OUT OF OR IN CONNECTION WITH SUCH PARTY'S PERFORMANCE
OR FAILURE TO PERFORM UNDER THIS AGREEMENT, OR RESULTING FROM, ARISING OUT OF
OR IN CONNECTION WITH THE PRODUCTION, SUPPLY, AND/OR SALE OF THE PRODUCTS OR
WAFERS OR ANY PART THEREOF WHETHER DUE TO A BREACH OF CONTRACT, BREACH OF
WARRANTY, TORT, OR NEGLIGENCE OF A PARTY, OR OTHERWISE. THIS SECTION DOES NOT
ELIMINATE A PARTY'S LIABILITY FOR ACTUAL DAMAGES.

Section 17. Term and Termination.

     17.1    Term. This Agreement shall remain in full force and effect for
three years from Effective Date. Either party has the right to terminate this
Agreement without cause with a

                                      -7-

<PAGE>   8
[MARVELL LOGO]                                     MARVELL TECHNOLOGY GROUP LTD.

thirty (30) day prior notice. This Agreement may be renewed by additional
periods by mutual written agreement of the parties.

        17.2    Termination for Breach. If either party breaches any material
term of condition of this Agreement and fails to cure that breach within thirty
(30) days after receiving written notice of the breach, the other party shall
have the right to terminate this Agreement, on written notice, at any time after
the end of such thirty (30) day period.

        17.3    Termination for Insolvency. If either party becomes the subject
of a voluntary or involuntary petition in bankruptcy or of any proceeding
relating to insolvency, receivership, liquidation, or composition for the
benefit of creditors, if that petition or proceeding is not dismissed with
prejudice within sixty (60) days after filing, the other party may terminate
this Agreement on thirty (30) days' notice.

        17.4    Return of Material. Upon termination or expiration of this
Agreement, TSMC shall return to MARVELL all items supplied to it under this
Agreement.

        17.5    Survival of Provisions. The rights and obligations of the
parties pursuant to Section 13, 15, 16 and 18 shall survive the termination of
this Agreement.

Section 18.     Miscellaneous.

        18.1    Governing Law. This Agreement shall be governed by and
interpreted in accordance with the laws of the State of California without
reference to conflict of laws principles.

        18.2    Arbitration. Any dispute or claim arising out of or in
connection with this Agreement shall be finally settled by binding arbitration
in San Jose, California under the rules of arbitration of the International
Chamber of Commerce by one arbitrator appointed in accordance with said rules.
Judgment on the award rendered by the arbitrator may be entered in any court
having jurisdiction thereof. Notwithstanding the foregoing, the parties may
apply to any court of competent jurisdiction for injunctive relief without
breach of this arbitration provision.

        18.3    Assignment. Neither party may assign or delegate this Agreement
or any of its licenses, rights or duties under this Agreement without the prior
written consent of the other, except MARVELL may assign this Agreement to a
person or entity into which it has merged or which has otherwise succeeded to
all of substantially all of its business and assets, and which has assumed in
writing or by operation of law its obligations under this Agreement.

        18.4    Authority. Each party represents that all corporate action
necessary for the authorization, execution and delivery of this Agreement by
such party and the performance of its obligations hereunder has been taken.

        18.5    Notices. All notices and other communications required or
permitted hereunder shall be in writing and shall be mailed by registered or
certified mail, postage prepaid, or


                                      -8-
<PAGE>   9
[MARVELL LOGO]                                     MARVELL TECHNOLOGY GROUP LTD.


otherwise delivered by hand, by messenger or by facsimile transmission,
addressed to the addresses set forth above or at such other address furnished
with a notice in the manner set forth herein. Such notices shall be deemed to
have been served when delivered or, if delivery is not accomplished by reason
of some fault of the addressee, when tendered.

     18.6   Partial Invalidity. If any paragraph, provision, or clause thereof
in this Agreement shall be found or be held to be invalid or unenforceable in
any jurisdiction in which this Agreement is being performed, the remainder of
this Agreement shall be valid and enforceable and the parties shall negotiate,
in good faith a substitute, valid and enforceable provision which most nearly
effects the parties' intent in entering into this Agreement.

     18.7   Counterparts. This Agreement may be executed in two (2) or more
counterparts, all of which, taken together, shall be regarded as one and the
same instrument.

     18.8   Waiver. The failure of either party to enforce at any time the
provisions of this Agreement shall in no way be constituted to be a present or
future waiver of such provisions, nor in any way affect the validity of either
party to enforce each and every such provision thereafter.

     18.9   Entire Agreement. The terms and conditions herein contained
constitute the entire agreement between the parties and supersede all previous
agreements and understandings, whether oral or written, between the parties
hereto with respect to the subject matter hereof and no agreement of
understanding varying or extending the same shall be binding upon either party
hereto unless in a written document signed by the party to be bound thereby.

     18.10 Section Headings. The section headings contained in this Agreement
are for reference purposes only and shall not affect in any way the meaning or
interpretation of this Agreement.

     18.11 Export Control. Export of Products from Taiwan may require export
authorization from the government of either Taiwan or another jurisdiction.
TSMC shall be responsible for the cost of obtaining such authorization or any
liability resulting from its failure to obtain such authorization.

     18.12 Terms to Other Customers. TSMC agrees that the terms and conditions
of any wafer purchase, production or supply agreement by and between TSMC and
any other customer under similar circumstances shall be no more favorable in
any material respect to such customer than those of this Agreement are to
MARVELL.

                            [Signature pages follow]


                                      -9-

<PAGE>   10
[MARVELL LOGO]

                                                   MARVELL TECHNOLOGY GROUP LTD.

        IN WITNESS WHEREOF the parties hereto have caused this Agreement to be
duly executed in duplicate on their behalf by their duly authorized officers and
representatives on the date given above.

MARVELL TECHNOLOGY GROUP, LTD.

By: /s/ WEILI DAI
   ----------------------------------
Name Weili Dai
     --------------------------------
Title Executive Vice President
      -------------------------------


TAIWAN SEMICONDUCTOR MANUFACTURING
CORPORATION

By: /s/ C.C. TSAI
   ----------------------------------
Name C.C. Tsai
     --------------------------------
Title Asia Sales Director
      -------------------------------
<PAGE>   11
[MARVELL LOGO]

                                                   MARVELL TECHNOLOGY GROUP LTD.

EXHIBITS LIST

Exhibit A       Acceptance Criteria

Exhibit B       Wafer Manufacturing Capacity Commitment

Exhibit C       Prices

<PAGE>   12
[MARVELL LOGO]

                                                   MARVELL TECHNOLOGY GROUP LTD.

                                   EXHIBIT A

                              ACCEPTANCE CRITERIA
<PAGE>   13



                                   EXHIBIT B

                    WAFER MANUFACTURING CAPACITY COMMITMENT

<TABLE>
<CAPTION>
Size         Unit Volume in 1997       Unit Volume in 1998      Unit Volume in 1999
<S>              <C>                       <C>                      <C>
 .5u             1,500                     15,000                   10,000
 .35u             prototypes*                5,000                   20,000
 .25u             0                         prototypes*               5,000
</TABLE>

*Demand for prototyping as noted indicates use of several hundred wafers
 annually in a given technology or feature size.
<PAGE>   14



[MARVELL LOGO]              EXHIBIT C              MARVELL TECHNOLOGY GROUP LTD.

            PRICES (STATED IN UNITED STATES DOLLARS) AND CYCLE TIMES